summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZuul <zuul@review.opendev.org>2019-09-30 20:04:48 +0000
committerGerrit Code Review <review@openstack.org>2019-09-30 20:04:48 +0000
commit19f2791082f906132c65770e50334648d8f0c6c0 (patch)
tree90897cc5de9ef4a7960e720d6df28ef396103892
parent80f1d6634ef4b259157c2fd2c95a33cab4153044 (diff)
parent381e81cfb24944ee1ebd8636af58d9bf6c35e76d (diff)
downloadkeystonemiddleware-19f2791082f906132c65770e50334648d8f0c6c0.tar.gz
Merge "Generate pdf documentation"
-rw-r--r--doc/requirements.txt3
-rw-r--r--doc/source/conf.py19
-rw-r--r--tox.ini12
3 files changed, 31 insertions, 3 deletions
diff --git a/doc/requirements.txt b/doc/requirements.txt
index 42dda5b..ddd05be 100644
--- a/doc/requirements.txt
+++ b/doc/requirements.txt
@@ -10,6 +10,9 @@ sphinx!=1.6.6,!=1.6.7,>=1.6.2,<2.0.0;python_version=='2.7' # BSD
sphinx!=1.6.6,!=1.6.7,!=2.1.0,>=1.6.2;python_version>='3.4' # BSD
sphinxcontrib-apidoc>=0.2.0 # BSD
+# PDF Docs
+sphinxcontrib-svg2pdfconverter>=0.1.0 # BSD
+
# For autodoc builds
mock>=2.0.0 # BSD
oslotest>=3.2.0 # Apache-2.0
diff --git a/doc/source/conf.py b/doc/source/conf.py
index ccea01f..4428242 100644
--- a/doc/source/conf.py
+++ b/doc/source/conf.py
@@ -42,6 +42,7 @@ extensions = ['sphinx.ext.todo',
'openstackdocstheme',
'oslo_config.sphinxconfiggen',
'sphinxcontrib.apidoc',
+ 'sphinxcontrib.rsvgconverter',
]
# sphinxcontrib.apidoc options
@@ -200,12 +201,24 @@ htmlhelp_basename = 'keystonemiddlewaredoc'
# (source start file, target name, title, author, documentclass [howto/manual])
# .
latex_documents = [
- ('index', 'keystonmiddleware.tex',
- 'keystonemiddleware Documentation',
- 'Nebula Inc, based on work by Rackspace and Jacob Kaplan-Moss',
+ ('index', 'doc-keystonemiddleware.tex',
+ u'keystonemiddleware Documentation',
+ u'Openstack Developers',
'manual'),
]
+# Disable usage of xindy https://bugzilla.redhat.com/show_bug.cgi?id=1643664
+latex_use_xindy = False
+
+latex_domain_indices = False
+
+latex_elements = {
+ 'extraclassoptions': 'openany',
+ 'makeindex': '',
+ 'printindex': '',
+ 'preamble': r'\setcounter{tocdepth}{3}',
+ 'maxlistdepth': 10,
+}
# The name of an image file (relative to this directory) to place at the top of
# the title page.
#latex_logo = None
diff --git a/tox.ini b/tox.ini
index d862926..5de16ff 100644
--- a/tox.ini
+++ b/tox.ini
@@ -64,6 +64,18 @@ commands=
doc8 doc/source
sphinx-build -W -b html doc/source doc/build/html
+[testenv:pdf-docs]
+basepython = python3
+envdir = {toxworkdir}/docs
+deps = {[testenv:docs]deps}
+whitelist_externals =
+ make
+ rm
+commands =
+ rm -rf doc/build/pdf
+ sphinx-build -W -b latex doc/source doc/build/pdf
+ make -C doc/build/pdf
+
[testenv:releasenotes]
basepython = python3
deps = -r{toxinidir}/doc/requirements.txt