1# -*- coding: utf-8 -*-
2#
3# Setuptools documentation build configuration file, created by
4# sphinx-quickstart on Fri Jul 17 14:22:37 2009.
5#
6# This file is execfile()d with the current directory set to its containing dir.
7#
8# The contents of this file are pickled, so don't put values in the namespace
9# that aren't pickleable (module imports are okay, they're removed automatically).
10#
11# Note that not all possible configuration values are present in this
12# autogenerated file.
13#
14# All configuration values have a default; values that are commented out
15# serve to show the default
16
17# If extensions (or modules to document with autodoc) are in another directory,
18# add these directories to sys.path here. If the directory is relative to the
19# documentation root, use os.path.abspath to make it absolute, like shown here.
20
21import subprocess
22import sys
23import os
24
25
26# hack to run the bootstrap script so that jaraco.packaging.sphinx
27# can invoke setup.py
28'READTHEDOCS' in os.environ and subprocess.check_call(
29    [sys.executable, 'bootstrap.py'],
30    cwd=os.path.join(os.path.dirname(__file__), os.path.pardir),
31)
32
33# -- General configuration -----------------------------------------------------
34
35# Add any Sphinx extension module names here, as strings. They can be extensions
36# coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
37extensions = ['jaraco.packaging.sphinx', 'rst.linker', 'sphinx.ext.autosectionlabel']
38
39# Add any paths that contain templates here, relative to this directory.
40templates_path = ['_templates']
41
42# The suffix of source filenames.
43source_suffix = '.txt'
44
45# The master toctree document.
46master_doc = 'index'
47
48# List of directories, relative to source directory, that shouldn't be searched
49# for source files.
50exclude_trees = []
51
52# The name of the Pygments (syntax highlighting) style to use.
53pygments_style = 'sphinx'
54
55# -- Options for HTML output ---------------------------------------------------
56
57# The theme to use for HTML and HTML Help pages.  Major themes that come with
58# Sphinx are currently 'default' and 'sphinxdoc'.
59html_theme = 'nature'
60
61# Add any paths that contain custom themes here, relative to this directory.
62html_theme_path = ['_theme']
63
64# If true, SmartyPants will be used to convert quotes and dashes to
65# typographically correct entities.
66html_use_smartypants = True
67
68# Custom sidebar templates, maps document names to template names.
69html_sidebars = {'index': 'indexsidebar.html'}
70
71# If false, no module index is generated.
72html_use_modindex = False
73
74# If false, no index is generated.
75html_use_index = False
76
77# -- Options for LaTeX output --------------------------------------------------
78
79# Grouping the document tree into LaTeX files. List of tuples
80# (source start file, target name, title, author, documentclass [howto/manual]).
81latex_documents = [
82  ('index', 'Setuptools.tex', 'Setuptools Documentation',
83   'The fellowship of the packaging', 'manual'),
84]
85
86link_files = {
87    '../CHANGES.rst': dict(
88        using=dict(
89            BB='https://bitbucket.org',
90            GH='https://github.com',
91        ),
92        replace=[
93            dict(
94                pattern=r'(Issue )?#(?P<issue>\d+)',
95                url='{package_url}/issues/{issue}',
96            ),
97            dict(
98                pattern=r'BB Pull Request ?#(?P<bb_pull_request>\d+)',
99                url='{BB}/pypa/setuptools/pull-request/{bb_pull_request}',
100            ),
101            dict(
102                pattern=r'Distribute #(?P<distribute>\d+)',
103                url='{BB}/tarek/distribute/issue/{distribute}',
104            ),
105            dict(
106                pattern=r'Buildout #(?P<buildout>\d+)',
107                url='{GH}/buildout/buildout/issues/{buildout}',
108            ),
109            dict(
110                pattern=r'Old Setuptools #(?P<old_setuptools>\d+)',
111                url='http://bugs.python.org/setuptools/issue{old_setuptools}',
112            ),
113            dict(
114                pattern=r'Jython #(?P<jython>\d+)',
115                url='http://bugs.jython.org/issue{jython}',
116            ),
117            dict(
118                pattern=r'Python #(?P<python>\d+)',
119                url='http://bugs.python.org/issue{python}',
120            ),
121            dict(
122                pattern=r'Interop #(?P<interop>\d+)',
123                url='{GH}/pypa/interoperability-peps/issues/{interop}',
124            ),
125            dict(
126                pattern=r'Pip #(?P<pip>\d+)',
127                url='{GH}/pypa/pip/issues/{pip}',
128            ),
129            dict(
130                pattern=r'Packaging #(?P<packaging>\d+)',
131                url='{GH}/pypa/packaging/issues/{packaging}',
132            ),
133            dict(
134                pattern=r'[Pp]ackaging (?P<packaging_ver>\d+(\.\d+)+)',
135                url='{GH}/pypa/packaging/blob/{packaging_ver}/CHANGELOG.rst',
136            ),
137            dict(
138                pattern=r'PEP[- ](?P<pep_number>\d+)',
139                url='https://www.python.org/dev/peps/pep-{pep_number:0>4}/',
140            ),
141            dict(
142                pattern=r'setuptools_svn #(?P<setuptools_svn>\d+)',
143                url='{GH}/jaraco/setuptools_svn/issues/{setuptools_svn}',
144            ),
145            dict(
146                pattern=r'^(?m)((?P<scm_version>v?\d+(\.\d+){1,2}))\n[-=]+\n',
147                with_scm='{text}\n{rev[timestamp]:%d %b %Y}\n',
148            ),
149        ],
150    ),
151}
152