From 20154dd39cfa5a94e910ff94723e3c34ebc5aa88 Mon Sep 17 00:00:00 2001 From: VirtuBox Date: Fri, 12 Jul 2019 14:11:01 +0200 Subject: [PATCH] Fix cwebp command --- optimize.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/optimize.sh b/optimize.sh index 1980584..febc0a1 100755 --- a/optimize.sh +++ b/optimize.sh @@ -195,7 +195,7 @@ if [ "$WEBP_OPTIMIZATION" = "y" ]; then bash -c '[ ! -f "{}.webp" ] && { cwebp -quiet -z 9 -mt "{}" -o "{}.webp"; }' else find . -type f -iname "*.png" -print0 | xargs -r -0 -I {} \ - bash -c '[ ! -f "{}.webp" ] && { cwebp -z 9 -mt "{}" -o "{}.webp"; }' + bash -c '[ ! -f "{}.webp" ] && { cwebp -z 9 -short -mt "{}" -o "{}.webp"; }' fi echo -ne " png to webp conversion [${CGREEN}OK${CEND}]\\r" @@ -209,7 +209,7 @@ if [ "$WEBP_OPTIMIZATION" = "y" ]; then bash -c '[ ! -f "{}.webp" ] && { cwebp -quiet -q 82 -mt "{}" -o "{}.webp"; }' else find . -type f \( -iname "*.jpg" -o -iname "*.jpeg" \) -print0 | xargs -0 -I {} \ - bash -c '[ ! -f "{}.webp" ] && { cwebp -q 82 -mt "{}" -o "{}.webp"; }' + bash -c '[ ! -f "{}.webp" ] && { cwebp -q 82 -short -mt "{}" -o "{}.webp"; }' fi echo -ne " jpg to webp conversion [${CGREEN}OK${CEND}]\\r"