Skip to content

Instantly share code, notes, and snippets.

Avatar

Sebastian Strindlund sebstr1

View GitHub Profile
View webp_batch.sh
#!/bin/bash
# Batch Convert all images in folder to webp.
# Create .sh file, paste this into the file, make it executable and run it; "./webp_batch.sh /path/to/folder/"
PATH=/usr/local/bin:/usr/bin:/bin
PARAMS=('cwebp -q 75 -alpha_q 10') # -alpha_q 10 is for images with transparent background
cd $1 || exit 1