Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .github/workflows/checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,10 @@ jobs:
working-directory: docs
run: uv run make dirhtml

- name: Verify Redirects
working-directory: docs
run: uv run make redirects-check

- name: Test Documentation
working-directory: docs
run: uv run make doctest
Expand Down
72 changes: 36 additions & 36 deletions README.md

Large diffs are not rendered by default.

29 changes: 28 additions & 1 deletion docs/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,34 @@ BUILDDIR = build
help:
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)

.PHONY: help Makefile
.PHONY: help Makefile redirects redirects-check

redirects:
@if [ -d "$(BUILDDIR)/dirhtml" ]; then \
python _redirects.py "$(BUILDDIR)/dirhtml"; \
elif [ -d "$(BUILDDIR)/html" ]; then \
python _redirects.py "$(BUILDDIR)/html"; \
else \
echo "No build directory found; run make html or make dirhtml first."; \
fi

redirects-check:
@if [ -d "$(BUILDDIR)/dirhtml" ]; then \
python _redirects.py --check "$(BUILDDIR)/dirhtml"; \
elif [ -d "$(BUILDDIR)/html" ]; then \
python _redirects.py --check "$(BUILDDIR)/html"; \
else \
echo "No build directory found; run make html or make dirhtml first."; \
exit 1; \
fi

html:
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
@python _redirects.py "$(BUILDDIR)/html"

dirhtml:
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
@python _redirects.py "$(BUILDDIR)/dirhtml"

# Catch-all target: route all unknown targets to Sphinx using the new
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
Expand Down
Loading
Loading