7 .
/usr
/lib
/tool
/bash-utils
11 pathbasename
=${mediafile%.*}
13 mediafile_new
=${pathbasename}-embedtn.
$ext
16 for tn_ext
in webp png jpg
18 tn_path
=$pathbasename.
$tn_ext
21 tn_path_new
=$pathbasename.png
25 dwebp
"$tn_path" -o "$tn_path_new"
28 convert
"$tn_path" "$tn_path_new"
36 AtomicParsley
"$mediafile" --artwork "$tn_path_new" -o "$mediafile_new"
37 mv "$mediafile_new" "$mediafile"
38 [ ! -e "$tn_path_new" ] ||
rm "$tn_path_new"
39 [ ! -e "$tn_path" ] ||
rm "$tn_path"
48 warnx
"thumbnail not found for $mediafile"