Created
September 14, 2020 12:17
-
-
Save frozenex/6d5343138737091d0563675c1a08b1c2 to your computer and use it in GitHub Desktop.
Bulk convert images to webp format using cwebp library in linux
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Copy this file to any directory containing images & then run this script in bash shell | |
# Get all png images in the current directory & convert it to webp format | |
for file in *.png ; | |
do | |
cwebp -q 80 "$file" -o "${file%.png}.webp"; | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment