Skip to content

Instantly share code, notes, and snippets.

@rmariuzzo
Created November 11, 2013 03:02
Show Gist options
  • Save rmariuzzo/7407117 to your computer and use it in GitHub Desktop.
Save rmariuzzo/7407117 to your computer and use it in GitHub Desktop.
Crush all PNG files in current directory.
#!/bin/sh
for file in *.png ; do pngcrush "$file" "${file%.png}-crushed.png" && mv "${file%.png}-crushed.png" "$file" ; done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment