1 2 3 4 5 6 7
#!/bin/sh for f in *.png; do out_file="${f%.*}.gif" if [ ! -f "$out_file" ]; then magick "$f" -background white -flatten -transparent white "$out_file" fi done