|
21 | 21 | # add these directories to sys.path here. If the directory is relative to the
|
22 | 22 | # documentation root, use os.path.abspath to make it absolute, like shown here.
|
23 | 23 | # sys.path.insert(0, os.path.abspath('.'))
|
| 24 | +import sphinx_rtd_theme |
| 25 | +from recommonmark.parser import CommonMarkParser |
| 26 | +from recommonmark.transform import AutoStructify |
| 27 | + |
24 | 28 | on_rtd = os.environ.get('READTHEDOCS', None) == 'True'
|
25 | 29 | if on_rtd:
|
26 | 30 | import inspect
|
|
57 | 61 | templates_path = ['_templates']
|
58 | 62 |
|
59 | 63 | # The suffix of source filenames.
|
60 |
| -source_suffix = '.rst' |
| 64 | +source_suffix = ['.rst', '.md'] |
61 | 65 |
|
62 | 66 | # The encoding of source files.
|
63 | 67 | # source_encoding = 'utf-8-sig'
|
|
120 | 124 |
|
121 | 125 | # The theme to use for HTML and HTML Help pages. See the documentation for
|
122 | 126 | # a list of builtin themes.
|
123 |
| -html_theme = 'bizstyle' |
| 127 | +html_theme = "sphinx_rtd_theme" |
124 | 128 |
|
125 | 129 | # Theme options are theme-specific and customize the look and feel of a theme
|
126 | 130 | # further. For a list of options available for each theme, see the
|
127 | 131 | # documentation.
|
128 |
| -# html_theme_options = {} |
| 132 | +html_theme_options = { |
| 133 | +} |
129 | 134 |
|
130 | 135 | # Add any paths that contain custom themes here, relative to this directory.
|
131 |
| -# html_theme_path = [] |
| 136 | +html_theme_path = [sphinx_rtd_theme.get_html_theme_path()] |
132 | 137 |
|
133 | 138 | # The name for this set of Sphinx documents. If None, it defaults to
|
134 | 139 | # "<project> v<release> documentation".
|
|
201 | 206 | # Output file base name for HTML help builder.
|
202 | 207 | htmlhelp_basename = 'core-doc'
|
203 | 208 |
|
204 |
| - |
205 | 209 | # -- Options for LaTeX output --------------------------------------------------
|
206 | 210 |
|
207 | 211 | latex_elements = {
|
208 |
| -# The paper size ('letterpaper' or 'a4paper'). |
209 |
| -# 'papersize': 'letterpaper', |
| 212 | + # The paper size ('letterpaper' or 'a4paper'). |
| 213 | + # 'papersize': 'letterpaper', |
210 | 214 |
|
211 |
| -# The font size ('10pt', '11pt' or '12pt'). |
212 |
| -# 'pointsize': '10pt', |
| 215 | + # The font size ('10pt', '11pt' or '12pt'). |
| 216 | + # 'pointsize': '10pt', |
213 | 217 |
|
214 |
| -# Additional stuff for the LaTeX preamble. |
215 |
| -# 'preamble': '', |
| 218 | + # Additional stuff for the LaTeX preamble. |
| 219 | + # 'preamble': '', |
216 | 220 | }
|
217 | 221 |
|
218 | 222 | # Grouping the document tree into LaTeX files. List of tuples
|
219 | 223 | # (source start file, targematplot name, title, author, documentclass [howto/manual]).
|
220 | 224 | latex_documents = [
|
221 |
| - ('index', 'user_guide.tex', u'QRL Documentation', |
222 |
| - u'The Quantum Resistant Ledger', 'manual'), |
| 225 | + ('index', 'user_guide.tex', u'QRL Documentation', |
| 226 | + u'The Quantum Resistant Ledger', 'manual'), |
223 | 227 | ]
|
224 | 228 |
|
225 | 229 | # The name of an image file (relative to this directory) to place at the top of
|
|
247 | 251 | intersphinx_mapping = {
|
248 | 252 | 'sphinx': ('http://sphinx.pocoo.org', None),
|
249 | 253 | 'python': ('http://docs.python.org/' + python_version, None),
|
250 |
| -# 'matplotlib': ('http://matplotlib.sourceforge.net', None), |
251 |
| -# 'numpy': ('http://docs.scipy.org/doc/numpy', None), |
252 |
| -# 'sklearn': ('http://scikit-learn.org/stable', None), |
253 |
| -# 'pandas': ('http://pandas.pydata.org/pandas-docs/stable', None), |
254 |
| -# 'scipy': ('http://docs.scipy.org/doc/scipy/reference/', None), |
| 254 | + # 'matplotlib': ('http://matplotlib.sourceforge.net', None), |
| 255 | + # 'numpy': ('http://docs.scipy.org/doc/numpy', None), |
| 256 | + # 'sklearn': ('http://scikit-learn.org/stable', None), |
| 257 | + # 'pandas': ('http://pandas.pydata.org/pandas-docs/stable', None), |
| 258 | + # 'scipy': ('http://docs.scipy.org/doc/scipy/reference/', None), |
255 | 259 | }
|
| 260 | + |
| 261 | +source_parsers = { |
| 262 | + '.md': CommonMarkParser, |
| 263 | +} |
| 264 | + |
| 265 | + |
| 266 | +def setup(app): |
| 267 | + app.add_config_value('recommonmark_config', { |
| 268 | + 'enable_eval_rst': True, |
| 269 | + }, True) |
| 270 | + app.add_transform(AutoStructify) |
0 commit comments