Put local Salt directory at the front of PYTHONPATH

Sphinx's autodoc was seeing the globally installed Salt over the local
copy.
This commit is contained in:
Seth House 2012-01-10 06:10:34 -07:00
parent b465bb2694
commit 4edf6da1ed

View File

@ -3,11 +3,13 @@
import sys, os
docs_basepath = os.path.abspath(os.path.join(os.path.dirname(__file__)))
addtl_paths = (
os.pardir, # salt directory (for autodoc)
'_ext', # custom Sphinx extensions
)
sys.path.extend([
os.path.join(docs_basepath, '..'), # salt directory (for autodoc)
os.path.join(docs_basepath, '_ext'), # Sphinx extensions
])
for path in addtl_paths:
sys.path.insert(0, os.path.abspath(os.path.join(docs_basepath, path)))
from salt import __version__