We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 46167b6 commit 2623a5bCopy full SHA for 2623a5b
compress-images.sh
@@ -0,0 +1,6 @@
1
+#!/bin/bash
2
+# Improved as per feedback from @pascal - https://gist.github.com/julianxhokaxhiu/c0a8e813eabf9d6d9873#gistcomment-3086462
3
+find . -type f -iname "*.png" -exec optipng -nb -nc {} \;
4
+find . -type f -iname "*.png" -exec advpng -z4 {} \;
5
+find . -type f -iname "*.png" -exec pngcrush -rem gAMA -rem alla -rem cHRM -rem iCCP -rem sRGB -rem time -ow {} \;
6
+find . -type f \( -iname "*.jpg" -o -iname "*.jpeg" \) -exec jpegoptim -f --strip-all {} \;
0 commit comments