#!/bin/bash

echo "<!doctype html>"
echo "<html><head><meta charset='utf-8'><title>Index of $(pwd)</title></head><body>"
echo "<h1>Index of $(pwd)</h1>"
echo "<ul>"

for f in *; do
  [ "$f" = "index.html" ] && continue
  echo "<li><a href=\"$f\">$f</a></li>"
done

echo "</ul>"
echo "</body></html>"

