diff options
| author | Sebastian Wiesner <basti.wiesner@gmx.net> | 2009-03-19 16:19:12 +0100 |
|---|---|---|
| committer | Sebastian Wiesner <basti.wiesner@gmx.net> | 2009-03-19 16:19:12 +0100 |
| commit | f239bb85e461346571ab645ef670026c0943690b (patch) | |
| tree | ac6ad7057ba565593e0f0820e465a0c6d8f49e46 | |
| parent | 75362e8cc9810c2c8afc16145b6b82cd1f8292c1 (diff) | |
| download | sphinx-f239bb85e461346571ab645ef670026c0943690b.tar.gz | |
#127: string-escape user-input from quickstart
| -rw-r--r-- | sphinx/quickstart.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/sphinx/quickstart.py b/sphinx/quickstart.py index cfdb97e7..0de45d3f 100644 --- a/sphinx/quickstart.py +++ b/sphinx/quickstart.py @@ -642,6 +642,12 @@ directly.''' mkdir_p(path.join(srcdir, d['dot'] + 'templates')) mkdir_p(path.join(srcdir, d['dot'] + 'static')) + def escape(key): + d[key] = d[key].encode('string-escape') + for key in ('project', 'copyright', 'version', 'release', + 'master', 'suffix'): + escape(key) + conf_text = QUICKSTART_CONF % d if d['ext_intersphinx'].upper() in ('Y', 'YES'): conf_text += INTERSPHINX_CONFIG |
