portfolio/scripts/process-images.sh
John Shaver 318a1eaecd
Some checks failed
continuous-integration/drone/push Build is failing
make the directory first, duh
2022-07-25 12:09:47 -07:00

19 lines
311 B
Bash
Executable file

#!/bin/bash
IMAGES_DIR="./images"
WIDTH=320
mkdir -p ./images/thumbnails
for f in ./images/*
do
case "$f" in
*.jpeg|*.jpg|*.png|*.webp|*.gif)
echo "Processing $f"
convert $f -resize $WIDTH\> ./images/thumbnails/th_`basename $f`
;;
*)
echo "Ignoring $f"
;;
esac
done