tox: Enable parallel docs build
This significantly speeds up our doc build process. This requires a newer version of 'sphinx-feature-classification' and some tweaks to our own in-tree extensions. While we're here, we drop the '-d DOCTREE_DIR' parameter since it's of no use when we blast away our previously built docs each time we build. Change-Id: I679da65d44c40880f720df8a2f06286a19eb8d22 Signed-off-by: Stephen Finucane <stephenfin@redhat.com>
This commit is contained in:
parent
d92c0740c6
commit
7062e1db8b
|
@ -224,7 +224,16 @@ class NovaDomain(domains.Domain):
|
||||||
)
|
)
|
||||||
return None
|
return None
|
||||||
|
|
||||||
|
def merge_domaindata(self, docnames, otherdata):
|
||||||
|
for target, docname in otherdata['extra_specs'].items():
|
||||||
|
if docname in docnames:
|
||||||
|
self.data['extra_specs'][target] = docname
|
||||||
|
|
||||||
|
|
||||||
def setup(app):
|
def setup(app):
|
||||||
app.add_domain(NovaDomain)
|
app.add_domain(NovaDomain)
|
||||||
app.add_directive('extra-specs', ExtraSpecGroupDirective)
|
app.add_directive('extra-specs', ExtraSpecGroupDirective)
|
||||||
|
return {
|
||||||
|
'parallel_read_safe': True,
|
||||||
|
'parallel_write_safe': True,
|
||||||
|
}
|
||||||
|
|
|
@ -576,3 +576,7 @@ class FeatureMatrixDirective(rst.Directive):
|
||||||
def setup(app):
|
def setup(app):
|
||||||
app.add_directive('feature_matrix', FeatureMatrixDirective)
|
app.add_directive('feature_matrix', FeatureMatrixDirective)
|
||||||
app.add_stylesheet('feature-matrix.css')
|
app.add_stylesheet('feature-matrix.css')
|
||||||
|
return {
|
||||||
|
'parallel_read_safe': True,
|
||||||
|
'parallel_write_safe': True,
|
||||||
|
}
|
||||||
|
|
|
@ -161,5 +161,9 @@ jQuery(document).ready(function(){
|
||||||
|
|
||||||
|
|
||||||
def setup(app):
|
def setup(app):
|
||||||
app.add_directive('versioned_notifications',
|
app.add_directive(
|
||||||
VersionedNotificationDirective)
|
'versioned_notifications', VersionedNotificationDirective)
|
||||||
|
return {
|
||||||
|
'parallel_read_safe': True,
|
||||||
|
'parallel_write_safe': True,
|
||||||
|
}
|
||||||
|
|
|
@ -5,7 +5,7 @@ sphinx>=2.0.0,!=2.1.0 # BSD
|
||||||
sphinxcontrib-actdiag>=0.8.5 # BSD
|
sphinxcontrib-actdiag>=0.8.5 # BSD
|
||||||
sphinxcontrib-seqdiag>=0.8.4 # BSD
|
sphinxcontrib-seqdiag>=0.8.4 # BSD
|
||||||
sphinxcontrib-svg2pdfconverter>=0.1.0 # BSD
|
sphinxcontrib-svg2pdfconverter>=0.1.0 # BSD
|
||||||
sphinx-feature-classification>=0.2.0 # Apache-2.0
|
sphinx-feature-classification>=1.1.0 # Apache-2.0
|
||||||
os-api-ref>=1.4.0 # Apache-2.0
|
os-api-ref>=1.4.0 # Apache-2.0
|
||||||
openstackdocstheme>=2.2.0 # Apache-2.0
|
openstackdocstheme>=2.2.0 # Apache-2.0
|
||||||
|
|
||||||
|
|
10
tox.ini
10
tox.ini
|
@ -185,7 +185,7 @@ deps =
|
||||||
-r{toxinidir}/doc/requirements.txt
|
-r{toxinidir}/doc/requirements.txt
|
||||||
commands =
|
commands =
|
||||||
rm -rf doc/build/html doc/build/doctrees
|
rm -rf doc/build/html doc/build/doctrees
|
||||||
sphinx-build -W --keep-going -b html -d doc/build/doctrees doc/source doc/build/html
|
sphinx-build -W --keep-going -b html -j auto doc/source doc/build/html
|
||||||
# Test the redirects. This must run after the main docs build
|
# Test the redirects. This must run after the main docs build
|
||||||
whereto doc/build/html/.htaccess doc/test/redirect-tests.txt
|
whereto doc/build/html/.htaccess doc/test/redirect-tests.txt
|
||||||
|
|
||||||
|
@ -196,7 +196,7 @@ envdir = {toxworkdir}/docs
|
||||||
deps = {[testenv:docs]deps}
|
deps = {[testenv:docs]deps}
|
||||||
commands =
|
commands =
|
||||||
rm -rf doc/build/pdf
|
rm -rf doc/build/pdf
|
||||||
sphinx-build -W -b latex doc/source doc/build/pdf
|
sphinx-build -W --keep-going -b latex -j auto doc/source doc/build/pdf
|
||||||
make -C doc/build/pdf
|
make -C doc/build/pdf
|
||||||
|
|
||||||
[testenv:api-guide]
|
[testenv:api-guide]
|
||||||
|
@ -206,7 +206,7 @@ envdir = {toxworkdir}/docs
|
||||||
deps = {[testenv:docs]deps}
|
deps = {[testenv:docs]deps}
|
||||||
commands =
|
commands =
|
||||||
rm -rf api-guide/build
|
rm -rf api-guide/build
|
||||||
sphinx-build -W --keep-going -b html -d api-guide/build/doctrees api-guide/source api-guide/build/html
|
sphinx-build -W --keep-going -b html -j auto api-guide/source api-guide/build/html
|
||||||
|
|
||||||
[testenv:api-ref]
|
[testenv:api-ref]
|
||||||
description =
|
description =
|
||||||
|
@ -215,7 +215,7 @@ envdir = {toxworkdir}/docs
|
||||||
deps = {[testenv:docs]deps}
|
deps = {[testenv:docs]deps}
|
||||||
commands =
|
commands =
|
||||||
rm -rf api-ref/build
|
rm -rf api-ref/build
|
||||||
sphinx-build -W --keep-going -b html -d api-ref/build/doctrees api-ref/source api-ref/build/html
|
sphinx-build -W --keep-going -b html -j auto api-ref/source api-ref/build/html
|
||||||
|
|
||||||
[testenv:releasenotes]
|
[testenv:releasenotes]
|
||||||
description =
|
description =
|
||||||
|
@ -224,7 +224,7 @@ envdir = {toxworkdir}/docs
|
||||||
deps = {[testenv:docs]deps}
|
deps = {[testenv:docs]deps}
|
||||||
commands =
|
commands =
|
||||||
rm -rf releasenotes/build
|
rm -rf releasenotes/build
|
||||||
sphinx-build -W --keep-going -b html -d releasenotes/build/doctrees releasenotes/source releasenotes/build/html
|
sphinx-build -W --keep-going -b html -j auto releasenotes/source releasenotes/build/html
|
||||||
|
|
||||||
[testenv:all-docs]
|
[testenv:all-docs]
|
||||||
description =
|
description =
|
||||||
|
|
Loading…
Reference in New Issue