mirror of
https://github.com/jupyterhub/jupyterhub.git
synced 2025-10-08 10:34:10 +00:00
build rest-api on RTD
This commit is contained in:
@@ -67,7 +67,8 @@ author = u'Project Jupyter team'
|
|||||||
# built documents.
|
# built documents.
|
||||||
# Project Jupyter uses the following to autopopulate version
|
# Project Jupyter uses the following to autopopulate version
|
||||||
from os.path import dirname
|
from os.path import dirname
|
||||||
root = dirname(dirname(dirname(__file__)))
|
docs = dirname(dirname(__file__))
|
||||||
|
root = dirname(docs)
|
||||||
sys.path.insert(0, root)
|
sys.path.insert(0, root)
|
||||||
|
|
||||||
import jupyterhub
|
import jupyterhub
|
||||||
@@ -382,5 +383,8 @@ if not on_rtd: # only import and set the theme if we're building docs locally
|
|||||||
import sphinx_rtd_theme
|
import sphinx_rtd_theme
|
||||||
html_theme = 'sphinx_rtd_theme'
|
html_theme = 'sphinx_rtd_theme'
|
||||||
html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]
|
html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]
|
||||||
|
else:
|
||||||
|
# build rest-api, since RTD doesn't run make
|
||||||
|
from subprocess import check_call as sh
|
||||||
|
sh(['make', 'rest-api'], cwd=docs)
|
||||||
# otherwise, readthedocs.org uses their theme by default, so no need to specify it
|
# otherwise, readthedocs.org uses their theme by default, so no need to specify it
|
||||||
|
Reference in New Issue
Block a user