Skip to content

Commit

Permalink
Build docs and run spellcheck on those instead of raw docs
Browse files Browse the repository at this point in the history
  • Loading branch information
tarek-y-ismail committed Oct 2, 2024
1 parent 9d177e0 commit 27e607f
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions doc/sphinx/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,14 @@ install: $(VENVDIR)
run: install
. $(VENV); sphinx-autobuild -b dirhtml "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS)

setup:
cd ../../; \
cmake -B .docs_build; \
cmake --build .docs_build --target doc -j12;
# cp -r .docs_build/doc/sphinx/_build doc/sphinx/_build
# cp -r .docs_build/doc/sphinx/xml doc/sphinx/xml


# Doesn't depend on $(BUILDDIR) to rebuild properly at every run.
html: install
. $(VENV); $(SPHINXBUILD) -b dirhtml "$(SOURCEDIR)" "$(BUILDDIR)" -w $(SPHINXDIR)/warnings.txt $(SPHINXOPTS)
Expand All @@ -90,8 +98,8 @@ clean-doc:
git clean -fx "$(BUILDDIR)"
rm -rf $(SPHINXDIR)/.doctrees

spelling: html
. $(VENV) ; python3 -m pyspelling -c $(SPHINXDIR)/spellingcheck.yaml -j $(shell nproc)
spelling: setup
. $(VENV); cd ../../.docs_build/doc/sphinx; python3 -m pyspelling -c $(SPHINXDIR)/spellingcheck.yaml -j $(shell nproc)

linkcheck: install
. $(VENV) ; $(SPHINXBUILD) -b linkcheck "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS)
Expand Down

0 comments on commit 27e607f

Please sign in to comment.