#!/bin/sh # $Id: makeIndex,v 1.4 2012/11/01 15:10:07 gdmr Exp $ # Take a directory full of thumb/* and whatever-* files, and generate an # index page displaying the former and linking to the latter. # Standard header first cat <Index page EoH # Now generate an index page as a table echo "" n=3 for t in thumbs/* ; do n=`expr $n + 1` if [ "$n" = "4" ] ; then echo "" n=0 fi s=`echo $t | sed -e 's/thumbs\///'` echo " " done echo "
" echo " \"$s\"" echo "
$s" echo "
" ## Raw links, as specifed on the command line #echo "" #echo "

Raw links:" #echo "

" # Finally the footer echo ""