Created
September 15, 2019 15:27
-
-
Save theraccoonbear/81e172419a045af8c3b0e1eba36e7b3a to your computer and use it in GitHub Desktop.
Generate a slideshow of images for cover art trivia
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Generate a slideshow of images for cover art trivia. | |
# Files should be named like {SORT-NUMBER} blah blah blah.jpg | |
for f in *.jpg; do | |
num=$(echo $f | sed -En "s/^([0-9]+).+?/\1/p") | |
formatNum="$((10#$num + 1 - 1))" | |
output=final_$num.jpg | |
echo "Processing $f file..."; | |
convert -caption "Cover #$formatNum" $f -pointsize 48 -gravity center -background black +polaroid $output | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment