mirror of
https://github.com/jupyterhub/jupyterhub.git
synced 2025-10-13 13:03:01 +00:00
Makefile: let make html depend on generated metrics.rst
This commit is contained in:
@@ -64,7 +64,7 @@ jobs:
|
|||||||
name: Build docs to store
|
name: Build docs to store
|
||||||
command: |
|
command: |
|
||||||
cd docs
|
cd docs
|
||||||
make metrics html
|
make html
|
||||||
# Tell Circle to store the documentation output in a folder that we can access later
|
# Tell Circle to store the documentation output in a folder that we can access later
|
||||||
- store_artifacts:
|
- store_artifacts:
|
||||||
path: docs/build/html/
|
path: docs/build/html/
|
||||||
|
@@ -61,10 +61,12 @@ rest-api: source/_static/rest-api/index.html
|
|||||||
source/_static/rest-api/index.html: rest-api.yml node_modules
|
source/_static/rest-api/index.html: rest-api.yml node_modules
|
||||||
npm run rest-api
|
npm run rest-api
|
||||||
|
|
||||||
metrics:
|
metrics: source/monitoring/_gen/metrics.rst
|
||||||
|
|
||||||
|
source/monitoring/_gen/metrics.rst: generate-metrics.py
|
||||||
python3 generate-metrics.py
|
python3 generate-metrics.py
|
||||||
|
|
||||||
html: rest-api
|
html: rest-api metrics
|
||||||
$(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html
|
$(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html
|
||||||
@echo
|
@echo
|
||||||
@echo "Build finished. The HTML pages are in $(BUILDDIR)/html."
|
@echo "Build finished. The HTML pages are in $(BUILDDIR)/html."
|
||||||
|
@@ -45,6 +45,7 @@ class Generator:
|
|||||||
content = f"{title}\n{underline}\n{writer.dumps()}"
|
content = f"{title}\n{underline}\n{writer.dumps()}"
|
||||||
with open(filename, 'w') as f:
|
with open(filename, 'w') as f:
|
||||||
f.write(content)
|
f.write(content)
|
||||||
|
print(f"Generated {filename}.")
|
||||||
|
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
|
@@ -217,7 +217,7 @@ intersphinx_mapping = {'https://docs.python.org/3/': None}
|
|||||||
on_rtd = os.environ.get('READTHEDOCS', None) == 'True'
|
on_rtd = os.environ.get('READTHEDOCS', None) == 'True'
|
||||||
if on_rtd:
|
if on_rtd:
|
||||||
# readthedocs.org uses their theme by default, so no need to specify it
|
# readthedocs.org uses their theme by default, so no need to specify it
|
||||||
# build rest-api, since RTD doesn't run make
|
# build both metrics and rest-api, since RTD doesn't run make
|
||||||
from subprocess import check_call as sh
|
from subprocess import check_call as sh
|
||||||
|
|
||||||
sh(['make', 'metrics', 'rest-api'], cwd=docs)
|
sh(['make', 'metrics', 'rest-api'], cwd=docs)
|
||||||
|
Reference in New Issue
Block a user