From 6b4d84b2169718204b3ad9bb32f28b76348812d8 Mon Sep 17 00:00:00 2001 From: Tin Lam Date: Sun, 14 May 2017 17:54:31 -0500 Subject: [PATCH] Fix rtd formatting This patch set addresses readthedocs.org loading oslosphinx, which results in some inconsistencies. It should simply use the rtd theme on the rtd environment. Change-Id: I35f599416d3764a2ed0961653b3ce45717335e72 --- doc/source/conf.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/doc/source/conf.py b/doc/source/conf.py index dc45aa96ca..61e8913d54 100755 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -21,11 +21,14 @@ sys.path.insert(0, os.path.abspath('../..')) # Add any Sphinx extension module names here, as strings. They can be # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom ones. extensions = [ - 'sphinx.ext.autodoc', - #'sphinx.ext.intersphinx', - 'oslosphinx' + 'sphinx.ext.autodoc' ] +on_rtd = os.environ.get('READTHEDOCS', None) == 'True' + +if not on_rtd: + extensions.append('oslosphinx') + # autodoc generation is a bit aggressive and a nuisance when doing heavy # text edit cycles. # execute "export SPHINX_DEBUG=1" in your terminal to disable