From cf3d72a1718e0511edf6be54eb8de894125acfee Mon Sep 17 00:00:00 2001 From: Tal Einat Date: Mon, 5 May 2014 15:13:56 +0300 Subject: [PATCH] fixing readthedocs.org WIP --- docs/conf.py | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/docs/conf.py b/docs/conf.py index 03b62fa..47f6a86 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -19,14 +19,17 @@ import sys, os # documentation root, use os.path.abspath to make it absolute, like shown here. #sys.path.insert(0, os.path.abspath('.')) -# Get the project root dir, which is the parent dir of this -cwd = os.getcwd() -project_root = os.path.dirname(cwd) +if os.getenv('READTHEDOCS', None) == 'True': + pass +else: + # Get the project root dir, which is the parent dir of this + cwd = os.getcwd() + project_root = os.path.dirname(cwd) -# Insert the project root dir as the first element in the PYTHONPATH. -# This lets us ensure that the source package is imported, and that its -# version is used. -sys.path.insert(0, project_root) + # Insert the project root dir as the first element in the PYTHONPATH. + # This lets us ensure that the source package is imported, and that its + # version is used. + sys.path.insert(0, project_root) import fuzzysearch