[READ-ONLY] Mirror of https://github.com/mrgnw/scripts.
0

Configure Feed

Select the types of activity you want to include in your feed.

scripts / avifs
328 B 20 lines
1#!/usr/bin/env zsh 2set -euo pipefail 3setopt nocaseglob 4 5if [[ ${#@} -gt 0 ]]; then 6 files=("$@") 7else 8 extensions=(${(f)"$(globs images -x avif)"}) 9 files=() 10 for ext in "${extensions[@]}"; do 11 files+=(${~ext}(N)) 12 done 13fi 14 15if [[ ${#files[@]} -eq 0 ]]; then 16 echo "No image files found." >&2 17 exit 1 18fi 19 20img2avif "${files[@]}"