# HG changeset patch # User Bernhard Herzog # Date 1213725981 0 # Node ID 8ec9ed76d67bc32f8712b08b3215d62b12c0d54e # Parent 13de20d2db9f6b2817c4b2dfef570615c158123a Make the template used by bin/publishstaticweb.py configurable. diff -r 13de20d2db9f -r 8ec9ed76d67b bin/publishstaticweb.py --- a/bin/publishstaticweb.py Wed Jun 11 12:59:17 2008 +0000 +++ b/bin/publishstaticweb.py Tue Jun 17 18:06:21 2008 +0000 @@ -1,5 +1,5 @@ #! /usr/bin/python2.4 -# Copyright (C) 2007 by Intevation GmbH +# Copyright (C) 2007, 2008 by Intevation GmbH # Authors: # Bernhard Herzog # @@ -28,7 +28,7 @@ """ return os.path.expandvars(os.path.expanduser(filename)) -staticweb_desc = ["build_user", "build_host", "build_create", +staticweb_desc = ["build_user", "build_host", "build_create", "build_template", ("build_dir", remove_trailing_slashes), "publish_user", "publish_host", ("publish_dir", remove_trailing_slashes), @@ -53,7 +53,8 @@ config = read_config(config_filename) # create web-page on build host - call(cmdexpand("ssh $build_user$@$build_host $build_create $build_dir", + call(cmdexpand("ssh $build_user$@$build_host $build_create" + " --status-template=$build_template $build_dir", **config)) # rsync the new web-pages to the local cache diff -r 13de20d2db9f -r 8ec9ed76d67b demostaticweb.cfg --- a/demostaticweb.cfg Wed Jun 11 12:59:17 2008 +0000 +++ b/demostaticweb.cfg Tue Jun 17 18:06:21 2008 +0000 @@ -17,6 +17,12 @@ # for that program works. build_create: ~/treepkg/bin/createstaticweb.py +# The template for the web-page. This value is passed as the +# --status-template argument to the build_create command on the build +# host. It should be either an absolute filename or a filename relative +# to the ~/treepkg/web/ directory. +build_template: status-by-startdate.html + # the directory on build_host where the static web-site should be put. # This value is used as the parameter to the build_create command on # build_host.