Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
#!/bin/bash
#Leaves the stats area intact and a 2px black
#border on the other edges. Saves file to a
#sub-direcotry
if [ ! -d ./PROCESSED ]; then mkdir ./PROCESSED;
fi
# processes all pngs
if ls | grep png; then for p in *.png;
do
echo "Processing $p"
convert \( $p -gravity south -crop 1204x862+0+0 +repage \) \
-background black -splice 0x2 \
./PROCESSED/${p/.png}_stats.png
done
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment