diff options
author | 2021-07-05 08:46:20 +0530 | |
---|---|---|
committer | 2021-07-06 04:37:03 +0530 | |
commit | 5c5740d89929de6f40c785f69b3b5897d7052343 (patch) | |
tree | 8253acc9d242fcf38d36eacc1b8deb81950da1f7 /scripts/minify-images.sh | |
parent | Removed references to png images since they were not being used anyways. (diff) | |
download | ferdium-recipes-5c5740d89929de6f40c785f69b3b5897d7052343.tar.gz ferdium-recipes-5c5740d89929de6f40c785f69b3b5897d7052343.tar.zst ferdium-recipes-5c5740d89929de6f40c785f69b3b5897d7052343.zip |
Removed minification of images since we no longer need binary image files.
Diffstat (limited to 'scripts/minify-images.sh')
-rwxr-xr-x | scripts/minify-images.sh | 12 |
1 files changed, 0 insertions, 12 deletions
diff --git a/scripts/minify-images.sh b/scripts/minify-images.sh deleted file mode 100755 index c248e08..0000000 --- a/scripts/minify-images.sh +++ /dev/null | |||
@@ -1,12 +0,0 @@ | |||
1 | #!/usr/bin/env sh | ||
2 | |||
3 | # Note: This script is needed due to this bug: https://github.com/imagemin/imagemin/issues/348 | ||
4 | # once the above is fixed, we should simply be able to specify the input directory where all image files are to be processed recursively | ||
5 | FILES=`find . -name "*.jpg" -o -name "*.jpeg" -o -name "*.bmp" -o -name "*.png" -type f | GREP_OPTIONS= egrep -v "node_modules"` | ||
6 | for file in $FILES; do | ||
7 | echo "Minifying file: $file" | ||
8 | size_before=`/usr/bin/du $file | cut -f1` | ||
9 | npx imagemin $file > $file.tmp && mv $file.tmp $file | ||
10 | size_after=`/usr/bin/du $file | cut -f1` | ||
11 | echo "$size_before -> $size_after" | ||
12 | done | ||