diff options
Diffstat (limited to '.local/share/bin')
-rwxr-xr-x | .local/share/bin/single2folder | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/.local/share/bin/single2folder b/.local/share/bin/single2folder new file mode 100755 index 0000000..b3b2d30 --- /dev/null +++ b/.local/share/bin/single2folder @@ -0,0 +1,16 @@ +#!/bin/sh +file=$1 +foldername=$(basename "$file" .flac) + +echo "mkdir \"$foldername\"" +mkdir "$foldername" + +echo "mv \"$file\" \"$foldername\"" +mv "$file" "$foldername" + +echo "extract folder.png" +metaflac --export-picture-to="${foldername}/folder.png" "${foldername}/${file}" + +echo "make sure folder.png is a png" +magick "${foldername}/folder.png" "${foldername}/folder.png" + |