Skip to content

Instantly share code, notes, and snippets.

@GwynethLlewelyn
Created May 12, 2024 09:28
Show Gist options
  • Save GwynethLlewelyn/b8cb97bf1c1c480fbf964bab3b3edd40 to your computer and use it in GitHub Desktop.
Save GwynethLlewelyn/b8cb97bf1c1c480fbf964bab3b3edd40 to your computer and use it in GitHub Desktop.
Batch conversion using ImageMagick
for file in *.png ; do
magick "$file" -define webp:lossless=true -define webp:auto-filter=true-define webp:filter-strength=50 -define webp:image-hint=picture -define webp:method=6 -define webp:thread-level=1 "${file%.*}.webp" ;
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment