From a085cf547a2c1265f164ebe9149178c8661001d7 Mon Sep 17 00:00:00 2001 From: Ryan May Date: Wed, 24 Jun 2015 11:12:05 -0600 Subject: [PATCH] Fix building docs on RTD. pandoc was broken by lack of HOME; just set one to keep it happy. --- docs/source/conf.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/docs/source/conf.py b/docs/source/conf.py index 1e9dca725..436854b01 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -21,6 +21,15 @@ # documentation root, use os.path.abspath to make it absolute, like shown here. sys.path.insert(0, os.path.abspath('.')) +# +# Read the docs fix +# On read the docs, there is no $HOME now, which breaks pandoc. Set one, +# which is unused, so that pandoc will run +# + +if 'READTHEDOCS' in os.environ and not 'HOME' in os.environ: + os.environ['HOME'] = '/home/docs' # Not sure what else to use + # -- General configuration ------------------------------------------------ # If your documentation needs a minimal Sphinx version, state it here.