From 0e03e2d45e36edb635229f356bf41f153c30a70f Mon Sep 17 00:00:00 2001 From: David Bremner Date: Sat, 11 Jul 2020 10:20:26 -0300 Subject: [PATCH] doc: replace use of environment variables with a generated config It is getting unwieldy to pass configuration options on the sphinx-build command line, and I anticipate further use of conditionals. As far as I could tell, execing a string is the idiomatic way to emulate include in Python. --- configure | 8 ++++++++ doc/Makefile.local | 2 +- doc/conf.py | 11 ++++++++--- 3 files changed, 17 insertions(+), 4 deletions(-) diff --git a/configure b/configure index 4e16ff40..c8690d3a 100755 --- a/configure +++ b/configure @@ -1548,6 +1548,14 @@ NOTMUCH_HAVE_PYTHON3_PYTEST=${have_python3_pytest} PLATFORM=${platform} EOF +cat > sphinx.config <> sphinx.config +fi +printf "rsti_dir = '%s'\n" $(realpath emacs) >> sphinx.config + # Finally, after everything configured, inform the user how to continue. cat <