From 93f07e609fbdf0461ea8ad7a61e15a12a3e2cbec Mon Sep 17 00:00:00 2001 From: uriel Date: Mon, 18 Jun 2007 01:45:45 +0200 Subject: [PATCH] Add feature to handle shared templates in pub/ and use it for a new sitemap template --- bin/controller.rc | 3 +++ pub/sitemap.tpl | 48 +++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 51 insertions(+) create mode 100644 pub/sitemap.tpl diff --git a/bin/controller.rc b/bin/controller.rc index 184f130..a523dd0 100755 --- a/bin/controller.rc +++ b/bin/controller.rc @@ -93,6 +93,8 @@ fn genbody { cat $body | /bin/sed -i '0,/]*>/d;/<\/body>/,$d' if not if ( ~ $body */[bB]log/index */[bB]log//index && ~ $#blogDirs 0 ) blogDirs = `{basename -d $body} + if not if ( test -f pub/^$reqpath^.tpl ) + template.awk pub/^$reqpath^.tpl | rc $rcargs if not if(~ $body */index && ~ $#blogDirs 0) { echo '

' `{basename `{basename -d $body}}'

' echo '