Browse Source

Right sphinx theme in local

pull/242/head
Florian Mounier 10 years ago
parent
commit
de64044910
  1. 13
      docs/conf.py

13
docs/conf.py

@ -15,7 +15,7 @@
import sys
import os
import shlex
# import shlex
# If extensions (or modules to document with autodoc) are in another directory,
# add these directories to sys.path here. If the directory is relative to the
@ -25,7 +25,7 @@ sys.path.insert(0, os.path.join(os.path.abspath('.'), 'ext'))
# -- General configuration ------------------------------------------------
# If your documentation needs a minimal Sphinx version, state it here.
#needs_sphinx = '1.0'
# needs_sphinx = '1.0'
# Add any Sphinx extension module names here, as strings. They can be
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
@ -112,6 +112,15 @@ pygments_style = 'sphinx'
todo_include_todos = False
# on_rtd is whether we are on readthedocs.org
on_rtd = os.environ.get('READTHEDOCS', None) == 'True'
if not on_rtd: # only import and set the theme if we're building docs locally
import sphinx_rtd_theme
html_theme = 'sphinx_rtd_theme'
html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]
# otherwise, readthedocs.org uses their theme by default, so no need to specify it
# -- Options for HTML output ----------------------------------------------
# The theme to use for HTML and HTML Help pages. See the documentation for

Loading…
Cancel
Save