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 | |
# 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\> \{} \; |