From a1447af69c3063bb154d343628a19134901549ff Mon Sep 17 00:00:00 2001 From: "Miss Islington (bot)" <31488909+miss-islington@users.noreply.github.com> Date: Mon, 13 Nov 2023 09:15:11 +0100 Subject: [3.12] Docs: Add `make htmllive` to rebuild and reload HTML files in your browser (GH-111900) (#112022) Co-authored-by: Hugo van Kemenade --- Doc/Makefile | 6 ++++++ Doc/requirements.txt | 1 + 2 files changed, 7 insertions(+) diff --git a/Doc/Makefile b/Doc/Makefile index 78ee427..7af56e9 100644 --- a/Doc/Makefile +++ b/Doc/Makefile @@ -29,6 +29,7 @@ help: @echo " venv to create a venv with necessary tools" @echo " html to make standalone HTML files" @echo " htmlview to open the index page built by the html target in your browser" + @echo " htmllive to rebuild and reload HTML files in your browser" @echo " htmlhelp to make HTML files and a HTML help project" @echo " latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter" @echo " text to make plain text files" @@ -139,6 +140,11 @@ pydoc-topics: build htmlview: html $(PYTHON) -c "import os, webbrowser; webbrowser.open('file://' + os.path.realpath('build/html/index.html'))" +.PHONY: htmllive +htmllive: SPHINXBUILD = $(VENVDIR)/bin/sphinx-autobuild +htmllive: SPHINXOPTS = --re-ignore="/venv/" +htmllive: html + .PHONY: clean clean: clean-venv -rm -rf build/* diff --git a/Doc/requirements.txt b/Doc/requirements.txt index 4741265..07d20a6 100644 --- a/Doc/requirements.txt +++ b/Doc/requirements.txt @@ -10,6 +10,7 @@ sphinx==4.5.0 blurb +sphinx-autobuild sphinxext-opengraph==0.7.5 # The theme used by the documentation is stored separately, so we need -- cgit v0.12