Skip to content

Commit

Permalink
doc: Clean up and modernize Sphinx configuration (fixes christiansand…
Browse files Browse the repository at this point in the history
…berg#463) (christiansandberg#465)

* Switch from setuptools' pkg_resources to importlib.metadata.

The remaining changes are based on a fresh invocation of sphinx-quickstart (version 7.2.6), trying to format our existing modifications in the same style.

* Update string literals to assume UTF-8 default.
* Remove commented Sphinx configuration options.
* Remove Sphinx options which are at their default.
* Reorder, project settings first.
* Remove explanatory comments on configuration options.
* Include section headers as generated via sphinx-quickstart.
* Remove default HTML theme option.
* Reorder (sort) extensions.
* Fix undefined default language.
* Rename modernized Sphinx options.
* Clean up section headings and move autodoc option down.
* Import Makefile generated by sphinx-quickstart.
  • Loading branch information
acolomb authored Jun 18, 2024
1 parent 3600880 commit 8f89d42
Show file tree
Hide file tree
Showing 2 changed files with 60 additions and 301 deletions.
20 changes: 20 additions & 0 deletions doc/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Minimal makefile for Sphinx documentation
#

# You can set these variables from the command line, and also
# from the environment for the first two.
SPHINXOPTS ?=
SPHINXBUILD ?= sphinx-build
SOURCEDIR = .
BUILDDIR = _build

# Put it first so that "make" without argument is like "make help".
help:
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)

.PHONY: help Makefile

# Catch-all target: route all unknown targets to Sphinx using the new
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
%: Makefile
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
Loading

0 comments on commit 8f89d42

Please sign in to comment.