tilde-town-website/gbcamera/generate_gallery_html.sh

19 lines
330 B
Bash
Raw Normal View History

#!/bin/sh
cat ./html_header
2021-02-06 07:11:32 +00:00
for image_dir in $(find -type d | egrep -v "^\.\$" | sort -r); do
date=$(echo "$image_dir" | xargs basename)
echo "<h3>$date</h3>"
echo "<ul>"
for image_file in $(find $image_dir -type f | sort); do
echo "<li><img src='$image_file'></li>"
done
echo "</ul>"
done
cat ./html_footer