diff options
author | Georg Brandl <georg@python.org> | 2011-10-07 11:39:19 +0200 |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2011-10-07 11:39:19 +0200 |
commit | 1b5db064bd78fcec62a67ef3d255970a83b7c336 (patch) | |
tree | ebf716c65b81a4ab261e3cc7e3fb5f16a79183de | |
parent | 69d082c1b7c50c06ad2ad506853c9b6a334d7960 (diff) | |
download | sphinx-1b5db064bd78fcec62a67ef3d255970a83b7c336.tar.gz |
Offer mathjax instead of jsmath in quickstart.
-rw-r--r-- | sphinx/apidoc.py | 13 | ||||
-rw-r--r-- | sphinx/quickstart.py | 10 |
2 files changed, 11 insertions, 12 deletions
diff --git a/sphinx/apidoc.py b/sphinx/apidoc.py index 6006943d..f988957e 100644 --- a/sphinx/apidoc.py +++ b/sphinx/apidoc.py @@ -231,7 +231,7 @@ def main(argv=sys.argv): usage: %prog [options] -o <output_path> <module_path> [exclude_paths, ...] Look recursively in <module_path> for Python modules and packages and create -a reST file with automodule directives per package in the <output_path>. +one reST file with automodule directives per package in the <output_path>. Note: By default this script will not overwrite already created files.""") @@ -241,13 +241,13 @@ Note: By default this script will not overwrite already created files.""") help='Maximum depth of submodules to show in the TOC ' '(default: 4)', type='int', default=4) parser.add_option('-f', '--force', action='store_true', dest='force', - help='Overwrite all the files') + help='Overwrite all files') parser.add_option('-n', '--dry-run', action='store_true', dest='dryrun', - help='Run the script without creating the files') + help='Run the script without creating files') parser.add_option('-T', '--no-toc', action='store_true', dest='notoc', - help='Don\'t create the table of contents file') + help='Don\'t create a table of contents file') parser.add_option('-H', '--doc-header', action='store', dest='header', - help='Documentation Header (default: Project)', + help='Documentation header (default: Project)', default='Project') parser.add_option('-s', '--suffix', action='store', dest='suffix', help='file suffix (default: rst)', default='rst') @@ -263,7 +263,6 @@ Note: By default this script will not overwrite already created files.""") print >>sys.stderr, '%s is not a directory.' % rootpath sys.exit(1) if not path.isdir(opts.destdir): - print '%s is not a valid output directory.' % opts.destdir - sys.exit(1) + os.makedirs(opts.destdir) excludes = normalize_excludes(rootpath, excludes) recurse_tree(rootpath, excludes, opts) diff --git a/sphinx/quickstart.py b/sphinx/quickstart.py index c7b3aaf8..1cdb46f8 100644 --- a/sphinx/quickstart.py +++ b/sphinx/quickstart.py @@ -897,10 +897,10 @@ Please indicate if you want to use one of the following Sphinx extensions:''' 'coverage (y/N)', 'n', boolean) do_prompt(d, 'ext_pngmath', 'pngmath: include math, rendered ' 'as PNG images (y/N)', 'n', boolean) - do_prompt(d, 'ext_jsmath', 'jsmath: include math, rendered in the ' - 'browser by JSMath (y/N)', 'n', boolean) - if d['ext_pngmath'] and d['ext_jsmath']: - print '''Note: pngmath and jsmath cannot be enabled at the same time. + do_prompt(d, 'ext_mathjax', 'mathjax: include math, rendered in the ' + 'browser by MathJax (y/N)', 'n', boolean) + if d['ext_pngmath'] and d['ext_mathjax']: + print '''Note: pngmath and mathjax cannot be enabled at the same time. pngmath has been deselected.''' do_prompt(d, 'ext_ifconfig', 'ifconfig: conditional inclusion of ' 'content based on config values (y/N)', 'n', boolean) @@ -921,7 +921,7 @@ directly.''' d['extensions'] = ', '.join( repr('sphinx.ext.' + name) for name in ('autodoc', 'doctest', 'intersphinx', 'todo', 'coverage', - 'pngmath', 'jsmath', 'ifconfig', 'viewcode') + 'pngmath', 'mathjax', 'ifconfig', 'viewcode') if d['ext_' + name]) d['copyright'] = time.strftime('%Y') + ', ' + d['author'] d['author_texescaped'] = unicode(d['author']).\ |