use virtualenv for sphinx builds
This commit is contained in:
parent
d42c006398
commit
edef2f0bf7
|
@ -0,0 +1 @@
|
||||||
|
venv
|
|
@ -0,0 +1,5 @@
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
virtualenv venv
|
||||||
|
venv/bin/pip install https://pypi.python.org/packages/11/b6/abcb525026a4be042b486df43905d6893fb04f05aac21c32c638e939e447/pip-9.0.1.tar.gz
|
||||||
|
venv/bin/pip install sphinx recommonmark
|
|
@ -166,7 +166,9 @@ def publish_sphinx(module):
|
||||||
checkout_dir = os.path.join(checkouts_directory, module.get('name'))
|
checkout_dir = os.path.join(checkouts_directory, module.get('name'))
|
||||||
output_dir = os.path.join(web_directory, module.get('name'))
|
output_dir = os.path.join(web_directory, module.get('name'))
|
||||||
build_dir = os.path.join(checkout_dir, '_build/html')
|
build_dir = os.path.join(checkout_dir, '_build/html')
|
||||||
os.system('cd %s && make html' % checkout_dir)
|
cmd = '%s/venv/bin/sphinx-build -b html -d _build/doctrees . _build/html' % os.getcwd()
|
||||||
|
os.system('cd %s && %s' % (checkout_dir, cmd))
|
||||||
|
shutil.rmtree(output_dir)
|
||||||
shutil.copytree(build_dir, output_dir)
|
shutil.copytree(build_dir, output_dir)
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue