Skip to content

Instantly share code, notes, and snippets.

@premasagar
Created June 12, 2010 19:04
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save premasagar/435982 to your computer and use it in GitHub Desktop.
Save premasagar/435982 to your computer and use it in GitHub Desktop.
Highest minification with pngcrush
# single image
pngcrush -rem alla -brute -reduce src.png dest.png
# directory of images
pngcrush -rem alla -brute -reduce -d outputdir ./*.png
# adapted from http://davidwalsh.name/pngcrush-directory
#!/bin/sh
for png in `find $1 -name "*.png"`; do; pngcrush -rem alla -brute -reduce "$png" temp.png; mv -f temp.png $png; done
@premasagar
Copy link
Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment