From 021b3208adb10cd25763450129c762042ed251a7 Mon Sep 17 00:00:00 2001 From: tv Date: Sun, 7 Feb 2010 01:59:29 +0100 Subject: Added handler for /dump.txt --- htgen.sh | 24 ++++++++++++++++++++++-- 1 file changed, 22 insertions(+), 2 deletions(-) diff --git a/htgen.sh b/htgen.sh index e94e714..ff401c8 100755 --- a/htgen.sh +++ b/htgen.sh @@ -54,9 +54,23 @@ case "$Host" in case "${Method-Invalid-Request}" in GET|HEAD) case "$Request_URI" in + /dump.txt) + body_type=file + body=~/public_html$Request_URI + status=200 + cat<&2 + #### XXX this is a hack: + ### make -C ~/public_html index.html >&2 # TODO 304 Not Modified # TODO better max-age(?) # TODO may we use more than one Cache-Control? body_type=file body=~/public_html/index.html + status=200 cat<&2 +echo "# OK: $status" >&2 exit -- cgit v1.2.3