Skip to content

Instantly share code, notes, and snippets.

@solarsailer
Created June 30, 2015 09:25
Show Gist options
  • Save solarsailer/3f0e418a27f82184bdf4 to your computer and use it in GitHub Desktop.
Save solarsailer/3f0e418a27f82184bdf4 to your computer and use it in GitHub Desktop.
Put in an Automator service with "Run Shell Script" (set with "Pass Input as Arguments").
for f in "$@"
do
mime=`file --mime-type $f`
if [[ $mime == *"image/"* ]]
then
/usr/local/bin/mogrify -scale 400% -strip $f
fi
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment