-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Update documentation related settings #6292
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,6 +7,10 @@ sphinx: | |
configuration: doc/conf.py | ||
|
||
python: | ||
version: 3.8 | ||
install: | ||
- requirements: doc/requirements.txt | ||
|
||
build: | ||
os: ubuntu-20.04 | ||
tools: | ||
python: "3.8" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -13,9 +13,9 @@ PYTHONPATH = | |
# Internal variables. | ||
PAPEROPT_a4 = -D latex_paper_size=a4 | ||
PAPEROPT_letter = -D latex_paper_size=letter | ||
ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) . | ||
ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees -T -E -W --keep-going $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) . | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I added these flags as they are also used by readthedocs and we therefore mimic that behaviour locally now |
||
|
||
.PHONY: help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest all | ||
.PHONY: help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck | ||
|
||
help: | ||
@echo "Please use \`make <target>' where <target> is one of" | ||
|
@@ -34,21 +34,21 @@ help: | |
@echo " man to make manual pages" | ||
@echo " changes to make an overview of all changed/added/deprecated items" | ||
@echo " linkcheck to check all external links for integrity" | ||
@echo " doctest to run all doctests embedded in the documentation (if enabled)" | ||
|
||
clean: | ||
-rm -rf $(BUILDDIR)/* | ||
-rm -f reference_guide/features.rst | ||
-rm -f extensions.rst | ||
|
||
html: features.rst extensions.rst | ||
html: | ||
@echo | ||
@echo "Install dependencies" | ||
$(PIP) install python-docs-theme | ||
$(PIP) install furo | ||
@echo "Finished installing dependencies" | ||
$(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html | ||
$(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) $(BUILDDIR)/linkcheck | ||
@echo | ||
@echo "Build finished. The HTML pages are in $(BUILDDIR)/html." | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
@echo "Link check complete; look for any errors in the above output " \ | ||
"or in $(BUILDDIR)/linkcheck/output.txt." | ||
|
||
|
||
dirhtml: | ||
$(SPHINXBUILD) -b dirhtml $(ALLSPHINXOPTS) $(BUILDDIR)/dirhtml | ||
|
@@ -132,22 +132,3 @@ linkcheck: | |
@echo | ||
@echo "Link check complete; look for any errors in the above output " \ | ||
"or in $(BUILDDIR)/linkcheck/output.txt." | ||
|
||
doctest: | ||
$(SPHINXBUILD) -b doctest $(ALLSPHINXOPTS) $(BUILDDIR)/doctest | ||
@echo "Testing of doctests in the sources finished, look at the " \ | ||
"results in $(BUILDDIR)/doctest/output.txt." | ||
|
||
|
||
extensions.rst: exts/pylint_extensions.py | ||
extensions.rst: $(shell find ../pylint/extensions -type f -regex '.*\.py') | ||
extensions.rst: $(shell find ../pylint/extensions -type f -regex '.*\.rst') | ||
rm -f extensions.rst | ||
PYTHONPATH=$(PYTHONPATH) $(PYTHON) ./exts/pylint_extensions.py | ||
|
||
features.rst: exts/pylint_features.py | ||
features.rst: $(shell find ../pylint/checkers -type f -regex '.*\.py') | ||
rm -f features.rst | ||
PYTHONPATH=$(PYTHONPATH) $(PYTHON) ./exts/pylint_features.py | ||
|
||
messages: $(PYTHONPATH) $(PYTHON) ./exts/pylint_messages.py |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can't add
linkcheck
to readthedocs as the only allow one build target (and they don't usemake html
butsphinx-build -b html
directly).Thus, we need our own CI to run
linkcheck
. Takes 2 additional minutes but I think that's okay considering the time most other jobs take.