--- scripts/pgallery/src/pgallery.sh 2012/08/28 17:29:32 1.8 +++ scripts/pgallery/src/pgallery.sh 2012/08/29 11:21:41 1.11 @@ -5,7 +5,7 @@ # can do whatever you want with this stuff. If we meet some day, and you think # this stuff is worth it, you can buy me a beer in return Aron Schlesinger # -# $Paefchen: scripts/pgallery/src/pgallery.sh,v 1.7 2012/08/28 17:08:34 as Exp $ +# $Paefchen: scripts/pgallery/src/pgallery.sh,v 1.10 2012/08/29 10:52:35 as Exp $ # ARG_TITLE="PGallery" @@ -33,7 +33,7 @@ BIN_EXIFTRAN="/usr/local/bin/exiftran" BIN_EXIF="/usr/local/bin/exif" MKAKEFILE=".htmakefile" -VERSION="pgallery-1.1" +VERSION="pgallery-1.2" # # usage() @@ -461,6 +461,20 @@ get_exif_info() echo $exifinfo | sed -e 's/ mm /mm /' -e 's/ sec./s/' -e 's/ ISO / ISO/' } +# +# is_in_list() +# +is_in_list() +{ + list=$1 + value=$2 + for entry in $list + do + test "$entry" = "$value" && return 0 + done + return 1 +} + # parse args while [ "$1" != "" ] do @@ -641,8 +655,25 @@ echo "tns: $targets" >> $MKAKEFILE make -f $MKAKEFILE rm $MKAKEFILE -# create single html files +# create html index index="" +for file in $FLIST +do + tn="${file}.tn.jpg" + imglink="${file}.html" + index="$index $(html_tn $tn $imglink)" +done +echo create html index +( + html_header + echo $index + echo "
" + echo "