Mercurial > treepkg > treepkg
diff bin/publishstaticweb.py @ 578:bccd69dedbe5
shlex.split all config parameters that may contain a command
Return the command as list and use @ operator for the variable in cmdexpand
author | Bjoern Ricks <bricks@intevation.de> |
---|---|
date | Sat, 03 Sep 2011 11:53:12 +0000 |
parents | ef87d30468b6 |
children |
line wrap: on
line diff
--- a/bin/publishstaticweb.py Sat Sep 03 11:48:00 2011 +0000 +++ b/bin/publishstaticweb.py Sat Sep 03 11:53:12 2011 +0000 @@ -9,6 +9,7 @@ """Publishes a static web-site with a status report""" import sys +import shlex import os from optparse import OptionParser from ConfigParser import SafeConfigParser @@ -28,7 +29,8 @@ """ return os.path.expandvars(os.path.expanduser(filename)) -staticweb_desc = ["build_user", "build_host", "build_create", "build_template", +staticweb_desc = ["build_user", "build_host", + ("build_create", shlex.split), "build_template", "build_logs", ("build_dir", remove_trailing_slashes), "publish_user", "publish_host", @@ -64,7 +66,7 @@ config = read_config(config_filename) # create web-page on build host - call(cmdexpand("ssh $build_user$@$build_host $build_create" + call(cmdexpand("ssh $build_user$@$build_host @build_create" " --show-logs=$build_logs" " --status-template=$build_template $build_dir", **config))