#!/bin/bash # # Creates thumbnail pictures and outputs an index file for browsers # thumbie -h for usage # FILES="$@" case "$FILES" in -h) cat <&2 Creates thumbnail pictures and outputs an index file for browsers Usage: thumbie Typical usage: thumbie *.JPG > index.html + edit index.html as needed + do 'chmod a+r index.html' END exit 0;; *) ;; esac echo "" echo "Title goes here" echo "" echo "

Details go here

" echo "

Click on images to obtain larger version.

" echo "

" for i in $FILES do chmod a+r $i djpeg $i | pnmscale -xysize 150 150 | cjpeg -opti -progr -qual 75 > TN_$i chmod a+r TN_$i echo "" done echo "

"