Commits

Josh VanderLinden committed 1236b47

Committing the patches... oops

Comments (0)

Files changed (2)

+# HG changeset patch
+# Parent 6cb09f68ce109215137d8b3c2079772770026763
+
+diff -r 6cb09f68ce10 sphinx/quickstart.py
+--- a/sphinx/quickstart.py	Thu Apr 22 07:30:37 2010 -0400
++++ b/sphinx/quickstart.py	Thu Apr 22 08:00:59 2010 -0400
+@@ -74,9 +74,9 @@
+ # built documents.
+ #
+ # The short X.Y version.
+-version = '%(version_str)s'
++#version = '%(version_str)s'
+ # The full version, including alpha/beta/rc tags.
+-release = '%(release_str)s'
++#release = '%(release_str)s'
+ 
+ # The language for content autogenerated by Sphinx. Refer to documentation
+ # for a list of supported languages.
+@@ -117,7 +117,7 @@
+ 
+ # The theme to use for HTML and HTML Help pages.  Major themes that come with
+ # Sphinx are currently 'default' and 'sphinxdoc'.
+-html_theme = 'default'
++html_theme = 'basic'
+ 
+ # Theme options are theme-specific and customize the look and feel of a theme
+ # further.  For a list of options available for each theme, see the
+@@ -129,7 +129,7 @@
+ 
+ # The name for this set of Sphinx documents.  If None, it defaults to
+ # "<project> v<release> documentation".
+-#html_title = None
++html_title = u'%(project_str)s'
+ 
+ # A shorter title for the navigation bar.  Default is the same as html_title.
+ #html_short_title = None
+@@ -282,21 +282,20 @@
+ '''
+ 
+ MASTER_FILE = '''\
+-.. %(project)s documentation master file, created by
+-   sphinx-quickstart on %(now)s.
++.. %(project)s master file, created by hgblog-quickstart on %(now)s.
+    You can adapt this file completely to your liking, but it should at least
+    contain the root `toctree` directive.
+ 
+-Welcome to %(project)s's documentation!
+-===========%(underline)s=================
++%(project)s
++%(underline)s
+ 
+ Contents:
+ 
+ .. toctree::
+    :maxdepth: 2
+ 
+-Indices and tables
+-==================
++Links
++=====
+ 
+ * :ref:`genindex`
+ * :ref:`modindex`
+@@ -671,27 +670,35 @@
+ 
+ 
+ def inner_main(args):
+-    d = {}
++    d = {
++        'sep': True,
++        'dot': '_',
++        'version': '',
++        'release': '',
++        'suffix': '.rst',
++        'master': 'index',
++        'epub': False,
++    }
+     texescape.init()
+ 
+     if not color_terminal():
+         nocolor()
+ 
+-    print bold('Welcome to the Sphinx %s quickstart utility.') % __version__
++    print bold('Welcome to the HgBlog %s quickstart utility.') % __version__
+     print '''
+ Please enter values for the following settings (just press Enter to
+ accept a default value, if one is given in brackets).'''
+ 
+     print '''
+-Enter the root path for documentation.'''
+-    do_prompt(d, 'path', 'Root path for the documentation', '.', is_path)
++Enter the root path for your blog articles.'''
++    do_prompt(d, 'path', 'Root path for your blog articles', '.', is_path)
+ 
+     while path.isfile(path.join(d['path'], 'conf.py')) or \
+           path.isfile(path.join(d['path'], 'source', 'conf.py')):
+         print
+         print bold('Error: an existing conf.py has been found in the '
+                    'selected root path.')
+-        print 'sphinx-quickstart will not overwrite existing Sphinx projects.'
++        print 'hgblog-quickstart will not overwrite existing HgBlog projects.'
+         print
+         do_prompt(d, 'path', 'Please enter a new root path (or just Enter '
+                   'to exit)', '', is_path)
+@@ -699,56 +706,9 @@
+             sys.exit(1)
+ 
+     print '''
+-You have two options for placing the build directory for Sphinx output.
+-Either, you use a directory "_build" within the root path, or you separate
+-"source" and "build" directories within the root path.'''
+-    do_prompt(d, 'sep', 'Separate source and build directories (y/N)', 'n',
+-              boolean)
+-
+-    print '''
+-Inside the root directory, two more directories will be created; "_templates"
+-for custom HTML templates and "_static" for custom stylesheets and other static
+-files. You can enter another prefix (such as ".") to replace the underscore.'''
+-    do_prompt(d, 'dot', 'Name prefix for templates and static dir', '_', ok)
+-
+-    print '''
+-The project name will occur in several places in the built documentation.'''
+-    do_prompt(d, 'project', 'Project name')
++The blog name will occur in several places in the HTML.'''
++    do_prompt(d, 'project', 'Blog name')
+     do_prompt(d, 'author', 'Author name(s)')
+-    print '''
+-Sphinx has the notion of a "version" and a "release" for the
+-software. Each version can have multiple releases. For example, for
+-Python the version is something like 2.5 or 3.0, while the release is
+-something like 2.5.1 or 3.0a1.  If you don't need this dual structure,
+-just set both to the same value.'''
+-    do_prompt(d, 'version', 'Project version')
+-    do_prompt(d, 'release', 'Project release', d['version'])
+-    print '''
+-The file name suffix for source files. Commonly, this is either ".txt"
+-or ".rst".  Only files with this suffix are considered documents.'''
+-    do_prompt(d, 'suffix', 'Source file suffix', '.rst', suffix)
+-    print '''
+-One document is special in that it is considered the top node of the
+-"contents tree", that is, it is the root of the hierarchical structure
+-of the documents. Normally, this is "index", but if your "index"
+-document is a custom template, you can also set this to another filename.'''
+-    do_prompt(d, 'master', 'Name of your master document (without suffix)',
+-              'index')
+-
+-    while path.isfile(path.join(d['path'], d['master']+d['suffix'])) or \
+-          path.isfile(path.join(d['path'], 'source', d['master']+d['suffix'])):
+-        print
+-        print bold('Error: the master file %s has already been found in the '
+-                   'selected root path.' % (d['master']+d['suffix']))
+-        print 'sphinx-quickstart will not overwrite the existing file.'
+-        print
+-        do_prompt(d, 'master', 'Please enter a new file name, or rename the '
+-                  'existing file and press Enter', d['master'])
+-
+-    print '''
+-Sphinx can also add configuration for epub output:'''
+-    do_prompt(d, 'epub', 'Do you want to use the epub builder (y/N)',
+-              'n', boolean)
+ 
+     print '''
+ Please indicate if you want to use one of the following Sphinx extensions:'''
+@@ -775,7 +735,7 @@
+               'of documented Python objects (y/N)', 'n', boolean)
+     print '''
+ A Makefile and a Windows command file can be generated for you so that you
+-only have to run e.g. `make html' instead of invoking sphinx-build
++only have to run e.g. `make html' instead of invoking hgbuild-build
+ directly.'''
+     do_prompt(d, 'makefile', 'Create Makefile? (Y/n)', 'y', boolean)
+     do_prompt(d, 'batchfile', 'Create Windows command file? (Y/n)',
+@@ -793,8 +753,8 @@
+     d['copyright'] = time.strftime('%Y') + ', ' + d['author']
+     d['author_texescaped'] = unicode(d['author']).\
+                              translate(texescape.tex_escape_map)
+-    d['project_doc'] = d['project'] + ' Documentation'
+-    d['project_doc_texescaped'] = unicode(d['project'] + ' Documentation').\
++    d['project_doc'] = d['project']
++    d['project_doc_texescaped'] = unicode(d['project']).\
+                                   translate(texescape.tex_escape_map)
+ 
+     # escape backslashes and single quotes in strings that are put into
+@@ -836,7 +796,7 @@
+ 
+     if d['makefile']:
+         d['rsrcdir'] = d['sep'] and 'source' or '.'
+-        d['rbuilddir'] = d['sep'] and 'build' or d['dot'] + 'build'
++        d['rbuilddir'] = d['sep'] and 'html' or d['dot'] + 'html'
+         # use binary mode, to avoid writing \r\n on Windows
+         f = open(path.join(d['path'], 'Makefile'), 'wb')
+         f.write((MAKEFILE % d).encode('utf-8'))
+@@ -844,25 +804,14 @@
+ 
+     if d['batchfile']:
+         d['rsrcdir'] = d['sep'] and 'source' or '.'
+-        d['rbuilddir'] = d['sep'] and 'build' or d['dot'] + 'build'
++        d['rbuilddir'] = d['sep'] and 'html' or d['dot'] + 'html'
+         f = open(path.join(d['path'], 'make.bat'), 'w')
+         f.write((BATCHFILE % d).encode('utf-8'))
+         f.close()
+ 
+     print
+     print bold('Finished: An initial directory structure has been created.')
+-    print '''
+-You should now populate your master file %s and create other documentation
+-source files. ''' % masterfile + ((d['makefile'] or d['batchfile']) and '''\
+-Use the Makefile to build the docs, like so:
+-   make builder
+-''' or '''\
+-Use the sphinx-build command to build the docs, like so:
+-   sphinx-build -b builder %s %s
+-''' % (srcdir, builddir)) + '''\
+-where "builder" is one of the supported builders, e.g. html, latex or linkcheck.
+-'''
+-
++    print '''You should now create some blog articles.'''
+ 
+ def main(argv=sys.argv):
+     try:
+# HG changeset patch
+# Parent 14ea69c060081944edea66ca8e111172d806fa63
+
+diff -r 14ea69c06008 .hgignore
+--- a/.hgignore	Sun Apr 18 09:41:44 2010 +0200
++++ b/.hgignore	Thu Apr 22 07:30:37 2010 -0400
+@@ -14,3 +14,4 @@
+ ^env/
+ \.DS_Store$
+ ~$
++.*\.swp
+diff -r 14ea69c06008 setup.py
+--- a/setup.py	Sun Apr 18 09:41:44 2010 +0200
++++ b/setup.py	Thu Apr 22 07:30:37 2010 -0400
+@@ -156,14 +156,14 @@
+ 
+ 
+ setup(
+-    name='Sphinx',
++    name='hgblog',
+     version=sphinx.__version__,
+     url='http://sphinx.pocoo.org/',
+     download_url='http://pypi.python.org/pypi/Sphinx',
+     license='BSD',
+-    author='Georg Brandl',
+-    author_email='georg@python.org',
+-    description='Python documentation generator',
++    author='Georg Brandl, Josh VanderLinden',
++    author_email='georg@python.org, codekoala@gmail.com',
++    description='Sphinx-based blogging engine',
+     long_description=long_desc,
+     zip_safe=False,
+     classifiers=[
+@@ -182,12 +182,12 @@
+     include_package_data=True,
+     entry_points={
+         'console_scripts': [
+-            'sphinx-build = sphinx:main',
+-            'sphinx-quickstart = sphinx.quickstart:main',
+-            'sphinx-autogen = sphinx.ext.autosummary.generate:main',
++            'hgblog-build = sphinx:main',
++            'hgblog-quickstart = sphinx.quickstart:main',
++            'hgblog-autogen = sphinx.ext.autosummary.generate:main',
+         ],
+         'distutils.commands': [
+-            'build_sphinx = sphinx.setup_command:BuildDoc',
++            'build_hgblog = sphinx.setup_command:BuildDoc',
+         ],
+     },
+     install_requires=requires,