blob: a6c57d17388564ff54e2c24e3024cfc54b2aa451 (
plain)
1
2
3
4
5
6
|
#!/bin/sh
#
set -eo pipefail
find ./ -type f -name '*.png' -not -path '*/.git/*' -exec sh -c 'cwebp -lossless $1 -o "${1%.png}.webp"' _ {} \;
find . -type f -not -path '*/.git/*' \( ! -iname ".gitignore" ! -iname "pre-commit" \) -exec sed -i -e 's/\.png/\.webp/g' {} \;
|