Skip to content

Instantly share code, notes, and snippets.

@oisin
Created January 14, 2013 12:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save oisin/4529781 to your computer and use it in GitHub Desktop.
Save oisin/4529781 to your computer and use it in GitHub Desktop.
Resize a bunch of tiff files to 865x585 and convert them to pngs. Used to convert screenshots to a good size for 1024x768 presentation slides.
#!/bin/bash
files=`find . -name '*.tiff'`
for f in $files
do
dir=`dirname $f`
target=`basename -s .tiff $f`
convert $f -resize 865x585 ${dir}/${target}_865x585.png
echo ${dir}/${target}_865x585.png
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment