From 19586d22e184714cdbea52ed67506ce7f7b985a6 Mon Sep 17 00:00:00 2001 From: Griatch Date: Sat, 30 Jan 2021 15:57:23 +0100 Subject: [PATCH] Update doc build makefile --- docs/Makefile | 11 +++-------- docs/source/conf.py | 4 +++- docs/source/toc.md | 2 +- 3 files changed, 7 insertions(+), 10 deletions(-) diff --git a/docs/Makefile b/docs/Makefile index bd079145ba..f70725fa4a 100644 --- a/docs/Makefile +++ b/docs/Makefile @@ -68,9 +68,7 @@ _autodoc-index: make _reformat_apidoc_headers _multiversion-autodoc-index: - make _clean_api_index - @EVDIR=$(EVDIR) EVGAMEDIR=$(EVGAMEDIR) SPHINX_APIDOC_OPTIONS=$(SPHINXAPIDOCENV) $(SPHINXAPIDOC) $(SPHINXAPIDOCOPTS) -o $(SOURCEDIR)/api/ $(EVDIR) $(SPHINXAPIDOCEXCLUDE) - make _reformat_apidoc_headers + make _autodoc-index git diff-index --quiet HEAD || git commit -a -m "Updated API autodoc index." || : _html-build: @@ -84,14 +82,11 @@ _multiversion-build: _multiversion-deploy: @bash -e deploy.sh - @EVDIR=$(EVDIR) EVGAMEDIR=$(EVGAMEDIR) $(SPHINXMULTIVERSION) $(SPHINXOPTS) "$(SOURCEDIR)" "$(BUILDDIR)/html" $(SPHINXOPTS) _latex-build: @NOAUTODOC=1 EVDIR=$(EVDIR) EVGAMEDIR=$(EVGAMEDIR) $(SPHINXBUILD) -M latexpdf "$(SOURCEDIR)" "$(BUILDDIR)/latex" $(QUICKFILES) -# main targets - -install: +# main target: @pip install -r requirements.txt clean: @@ -128,7 +123,7 @@ local: mv-local: make _multiversion-check-env make clean - make _multiversion-autodoc-index + #make _multiversion-autodoc-index make _multiversion-build @echo "" @echo "Documentation built (multiversion + autodocs)." diff --git a/docs/source/conf.py b/docs/source/conf.py index 01c7dc8ad6..13d7969aec 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -187,7 +187,9 @@ if not _no_autodoc: ) raise RuntimeError(err) - print("Evennia root: {}, Game dir: {}".format(EV_ROOT, GAME_DIR)) + print("Evennia root: {}, Game dir: {}, branch:".format(EV_ROOT, GAME_DIR)), + import subprocess + subprocess.call(["git", "rev-parse", "--abbrev-ref", "HEAD"]) sys.path.insert(1, EV_ROOT) sys.path.insert(1, GAME_DIR) diff --git a/docs/source/toc.md b/docs/source/toc.md index b2e6dbbe51..5ad330aff6 100644 --- a/docs/source/toc.md +++ b/docs/source/toc.md @@ -1,5 +1,5 @@ # Toc - +- [API root](api/evennia-api.rst) - [Coding/Coding Introduction](Coding/Coding-Introduction) - [Coding/Coding Overview](Coding/Coding-Overview) - [Coding/Continuous Integration](Coding/Continuous-Integration)