Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
bulk-scale-images.sh
#!/bin/bash
# Max Width
WIDTH=1200
# Max Height
HEIGHT=800
# Resize .jpg or .png to either height or width, preserve aspect ration:
find . -type f \( -name "*.jpg" -o -name "*.png" \) -exec convert \{} -verbose -resize $WIDTHx$HEIGHT\> \{} \;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.