Last active 5 days ago

Use this command to compress an image and strip all metadata from it.

gistfile1.txt Raw
1function reduceimage {
2magick "$1" \
3 -resize "${2:-2000}x${2:-2000}>" \
4 -strip \
5 -quality 45 \
6 -define webp:lossless=false \
7 "${1%.*}-r.webp"
8}