20bf587d68
In change I48b923a67010c92945c46ab00de0b090ba7cd465, way back in 2016, we started hiding duplicate titles caused by us including the first h1 title we found at the top of the page. Unfortunately, the fix for this was to hide *all* h1 titles found in the main docs body. Sphinx doesn't insist on only a single h1 title (in fact, the sphinx-quickstart tool produces an index.rst with two h1 titles) which means we were hiding a lot of information unwittingly. Fix this by only hiding the first title, as originally intended. Also replace deprecated whitelist_externals by allowlist_externals in tox.ini. Change-Id: Ic8fc5e1256b4ab8925401fe6781210729a68d2aa Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
90 lines
2.7 KiB
INI
90 lines
2.7 KiB
INI
[tox]
|
|
minversion = 3.1.0
|
|
envlist = pep8
|
|
ignore_basepython_conflict = true
|
|
|
|
[testenv]
|
|
basepython = python3
|
|
usedevelop = true
|
|
deps =
|
|
-c{env:TOX_CONSTRAINTS_FILE:https://opendev.org/openstack/requirements/raw/upper-constraints.txt}
|
|
-r{toxinidir}/test-requirements.txt
|
|
-r{toxinidir}/requirements.txt
|
|
-r{toxinidir}/doc/requirements.txt
|
|
sitepackages = False
|
|
allowlist_externals =
|
|
rm
|
|
make
|
|
|
|
[testenv:pep8]
|
|
commands =
|
|
pre-commit run -a
|
|
flake8 openstackdocstheme
|
|
|
|
[testenv:venv]
|
|
commands = {posargs}
|
|
|
|
[testenv:docs]
|
|
commands =
|
|
rm -rf doc/build/html doc/build/doctrees
|
|
sphinx-build -a -E -W -j auto -d doc/build/doctrees -b html doc/source doc/build/html
|
|
|
|
[testenv:docs-starlingxdocs]
|
|
envdir = {toxworkdir}/docs
|
|
commands =
|
|
rm -rf doc/build/html doc/build/doctrees
|
|
sphinx-build -a -E -W -j auto -d doc/build/doctrees -b html -D html_theme=starlingxdocs doc/source doc/build/html
|
|
|
|
[testenv:html]
|
|
commands =
|
|
rm -rf doc/build/html doc/build/doctrees api-ref/build
|
|
sphinx-build -a -E -W -j auto -d doc/build/doctrees -b html doc/source doc/build/html
|
|
sphinx-build -a -E -W -j auto -d api-ref/build/doctrees -b html api-ref/source api-ref/build/html
|
|
|
|
[testenv:releasenotes]
|
|
commands =
|
|
rm -rf releasenotes/build
|
|
sphinx-build -a -E -W -j auto -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html
|
|
|
|
[testenv:releasenotes-starlingxdocs]
|
|
commands =
|
|
rm -rf releasenotes/build
|
|
sphinx-build -a -E -W -j auto -d releasenotes/build/doctrees -b html -D html_theme=starlingxdocs releasenotes/source releasenotes/build/html
|
|
|
|
[testenv:api-ref]
|
|
commands =
|
|
rm -rf api-ref/build
|
|
sphinx-build -a -E -W -j auto -d api-ref/build/doctrees -b html api-ref/source api-ref/build/html
|
|
|
|
[testenv:api-ref-starlingxdocs]
|
|
commands =
|
|
rm -rf api-ref/build
|
|
sphinx-build -a -E -W -j auto -d api-ref/build/doctrees -b html -D html_theme=starlingxdocs api-ref/source api-ref/build/html
|
|
|
|
[testenv:pdf-docs]
|
|
envdir = {toxworkdir}/docs
|
|
commands =
|
|
rm -rf doc/build/pdf
|
|
sphinx-build -a -E -W -j auto -b latex doc/source doc/build/pdf
|
|
make -C doc/build/pdf
|
|
|
|
[testenv:pdf-docs-starlingxdocs]
|
|
envdir = {toxworkdir}/docs
|
|
commands =
|
|
rm -rf doc/build/pdf
|
|
sphinx-build -a -E -W -j auto -b latex -D html_theme=starlingxdocs doc/source doc/build/pdf
|
|
make -C doc/build/pdf
|
|
|
|
[testenv:bindep]
|
|
# Do not install any requirements. We want this to be fast and work even if
|
|
# system dependencies are missing, since it's used to tell you what system
|
|
# dependencies are missing! This also means that bindep must be installed
|
|
# separately, outside of the requirements files.
|
|
deps = bindep
|
|
commands = bindep test
|
|
|
|
[flake8]
|
|
exclude=.venv,.git,.tox,dist,doc,api-ref,*lib/python*,*egg,tools
|
|
show-source = True
|
|
enable-extensions = H203,H106
|