changelog shortlog tags branches files raw gz bz2 help

Mercurial > hg > werc / changeset: Get rid of response_format which was only used by blagh feeds anyway, and we can emulate by setting $headers to nil plus adding a $res_tail var.

changeset 317: c062cb8f9c32
parent 316: a8c8620f7ff7
child 318: dcc289b14b9f
author: uriel@engel.se.cat-v.org
date: Tue, 13 Jan 2009 03:18:19 +0100
files: bin/werc.rc
description: Get rid of response_format which was only used by blagh feeds anyway, and we can emulate by setting $headers to nil plus adding a $res_tail var.
     1.1--- a/bin/werc.rc	Mon Jan 12 02:07:31 2009 +0100
     1.2+++ b/bin/werc.rc	Tue Jan 13 03:18:19 2009 +0100
     1.3@@ -3,7 +3,6 @@
     1.4 cd ..
     1.5 
     1.6 forbidden_uri_chars='[^a-zA-Z0-9_+\-\/\.]'
     1.7-response_format=html
     1.8 
     1.9 fn get_lib_file {
    1.10     if(test -f $sitedir/_werc/lib/$1)
    1.11@@ -133,6 +132,7 @@
    1.12 
    1.13 headers=lib/headers.tpl
    1.14 master_template=default_master.tpl
    1.15+res_tail='</body></html>'
    1.16 sidebar=sidebar
    1.17 werc_root=`{pwd}
    1.18 for(i in siteTitle siteSubTitle pageTitle extraHeaders)
    1.19@@ -210,12 +210,5 @@
    1.20 if(! ~ $#debug 0)
    1.21     dprint '  '$"SERVER_NAME^$"REQUEST_URI' - '$"HTTP_USER_AGENT' - '$"REQUEST_METHOD' - '$"handler
    1.22 
    1.23-# Template/body selection
    1.24-master_template=`{get_lib_file $master_template}
    1.25-
    1.26-if(~ $response_format html) {
    1.27-    template $headers $master_template | awk_buffer
    1.28-    echo '</body></html>'
    1.29-}
    1.30-if not if(~ $response_format raw)
    1.31-    template < $master_template 
    1.32+template $headers `{get_lib_file $master_template} | awk_buffer
    1.33+echo $res_tail