summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIan Lee <IanLee1521@gmail.com>2015-09-09 08:34:35 -0700
committerIan Lee <IanLee1521@gmail.com>2015-09-09 08:34:35 -0700
commit870509191e75b3914e0d92a08767c6dc492d8ccd (patch)
tree650e5477988a8aa0ac78315f60bc390e95e7f0b6
parent37648d3fb74db1fd952c7cb101eaf7224055ce1b (diff)
downloadpep8-870509191e75b3914e0d92a08767c6dc492d8ccd.tar.gz
Fixed issue with mixed theme on RTD
-rw-r--r--docs/conf.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/docs/conf.py b/docs/conf.py
index d7d9291..d58549d 100644
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -99,7 +99,11 @@ pygments_style = 'sphinx'
# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.
-html_theme = 'alabaster'
+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()]
# 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