Skip to content

Instantly share code, notes, and snippets.

@edwinvdgraaf
Created March 6, 2014 12:13
Show Gist options
  • Save edwinvdgraaf/9388328 to your computer and use it in GitHub Desktop.
Save edwinvdgraaf/9388328 to your computer and use it in GitHub Desktop.
#!/bin/bash
# Downsamples all retina [email protected] images.
for f in $(find . -name '*@2x.png'); do
echo "Converting $f..."
convert "$f" -resize '50%' "$(dirname $f)/$(basename -s '@2x.png' $f).png"
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment