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
|
||||
|
||||
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):
|
||||
app.add_domain(NovaDomain)
|
||||
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):
|
||||
app.add_directive('feature_matrix', FeatureMatrixDirective)
|
||||
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):
|
||||
app.add_directive('versioned_notifications',
|
||||
VersionedNotificationDirective)
|
||||
app.add_directive(
|
||||
'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-seqdiag>=0.8.4 # 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
|
||||
openstackdocstheme>=2.2.0 # Apache-2.0
|
||||
|
||||
|
10
tox.ini
10
tox.ini
@ -185,7 +185,7 @@ deps =
|
||||
-r{toxinidir}/doc/requirements.txt
|
||||
commands =
|
||||
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
|
||||
whereto doc/build/html/.htaccess doc/test/redirect-tests.txt
|
||||
|
||||
@ -196,7 +196,7 @@ envdir = {toxworkdir}/docs
|
||||
deps = {[testenv:docs]deps}
|
||||
commands =
|
||||
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
|
||||
|
||||
[testenv:api-guide]
|
||||
@ -206,7 +206,7 @@ envdir = {toxworkdir}/docs
|
||||
deps = {[testenv:docs]deps}
|
||||
commands =
|
||||
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]
|
||||
description =
|
||||
@ -215,7 +215,7 @@ envdir = {toxworkdir}/docs
|
||||
deps = {[testenv:docs]deps}
|
||||
commands =
|
||||
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]
|
||||
description =
|
||||
@ -224,7 +224,7 @@ envdir = {toxworkdir}/docs
|
||||
deps = {[testenv:docs]deps}
|
||||
commands =
|
||||
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]
|
||||
description =
|
||||
|
Loading…
x
Reference in New Issue
Block a user