#!/bin/ksh chmod +w * chmod +r * chgrp botany * for file in asp*.jpg do output=`echo $file | sed -e 's/.jpg/.gifs/'` if [[ ! -a $output ]] then echo "doing $file, outputting to $output" djpeg -P $file | pnmscale -xysize 120 120 | ppmquant 256 | ppmtogif > $output fi done