From b5fa9e6f4c48005133d3af0db7dbfd460d5a943a Mon Sep 17 00:00:00 2001 From: materus Date: Fri, 23 Aug 2024 18:47:47 +0200 Subject: [PATCH] scripts: convert: another change quality --- extraFiles/scripts/convert_images.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/extraFiles/scripts/convert_images.sh b/extraFiles/scripts/convert_images.sh index 78cc4ac..c49cee2 100755 --- a/extraFiles/scripts/convert_images.sh +++ b/extraFiles/scripts/convert_images.sh @@ -3,7 +3,7 @@ IFS=$'\n' CONVERT="$(nix eval nixpkgs\#imagemagick.outPath | tr -d '"')/bin/convert" convert_cmd () { -if ! command -v convert &> /dev/null; then $CONVERT "$@"; else convert "$@"; fi +if ! command -v magick &> /dev/null; then $CONVERT "$@"; else convert "$@"; fi } @@ -19,7 +19,7 @@ change_to_webp() { file="${f%.*}" file_webp="${file}.webp" echo "Trying to convert to $file_webp" - if convert_cmd "$f" "$file_webp"; then + if convert_cmd "$f" -define webp:thread-level=1 -define webp:method=6 -quality 99 "$file_webp"; then if touch -r "$f" "$file_webp"; then rm "$f" echo "Finished converting $f"