Add PDF documentation build

Add a new tox target to build PDF documentation in accord
with the community goal [0] to have PDF docs available.

Also, only show genindex and search for HTML.  These elements
do not make sense within PDF documents.

[0] https://governance.openstack.org/tc/goals/selected/train/pdf-doc-generation.html

Change-Id: Ibbd50276c3879958b0ceb82afcc882716c01b384
This commit is contained in:
Tom Barron 2019-09-11 11:53:47 -04:00
parent cc401e5333
commit 6c6b0bd5b2
4 changed files with 56 additions and 7 deletions

View File

@ -10,9 +10,11 @@ Team and repository tags
Python bindings to the OpenStack Manila API Python bindings to the OpenStack Manila API
=========================================== ===========================================
.. image:: https://img.shields.io/pypi/v/python-manilaclient.svg .. only: html
:target: https://pypi.org/project/python-manilaclient/
:alt: Latest Version .. image:: https://img.shields.io/pypi/v/python-manilaclient.svg
:target: https://pypi.org/project/python-manilaclient/
:alt: Latest Version
This is a client for the OpenStack Manila API. There's a Python API (the This is a client for the OpenStack Manila API. There's a Python API (the
``manilaclient`` module), and a command-line script (``manila``). Each ``manilaclient`` module), and a command-line script (``manila``). Each

View File

@ -82,3 +82,38 @@ bug_project = 'python-manilaclient'
bug_tag = 'docs' bug_tag = 'docs'
html_last_updated_fmt = '%Y-%m-%d %H:%M' html_last_updated_fmt = '%Y-%m-%d %H:%M'
# -- Options for LaTeX output -------------------------------------------------
# Docs job does not install xindy
latex_use_xindy = False
# The paper size ('letter' or 'a4').
# latex_paper_size = 'letter'
# The font size ('10pt', '11pt' or '12pt').
# latex_font_size = '10pt'
# Grouping the document tree into LaTeX files. List of tuples
# (source start file, target name, title, author, documentclass
# [howto/manual]).
latex_documents = [
('index', 'Manila-client.tex', u'Manila Python Client Documentation',
u'Manila contributors', 'manual'),
]
# The name of an image file (relative to this directory) to place at the top of
# the title page.
# latex_logo = None
# For "manual" documents, if this is true, then toplevel headings are parts,
# not chapters.
# latex_use_parts = False
# Additional stuff for the LaTeX preamble.
# latex_preamble = ''
# Documents to append as an appendix to all manuals.
# latex_appendices = []
# If false, no module index is generated.
# latex_use_modindex = True

View File

@ -33,8 +33,10 @@ Contributing
contributor/index contributor/index
Indices and tables .. only:: html
==================
* :ref:`genindex` Indices and tables
* :ref:`search` ==================
* :ref:`genindex`
* :ref:`search`

10
tox.ini
View File

@ -49,6 +49,16 @@ commands =
rm -rf doc/build rm -rf doc/build
sphinx-build -b html doc/source doc/build/html sphinx-build -b html doc/source doc/build/html
[testenv:pdf-docs]
usedevelop = True
basepthon = python3
deps = {[testenv:docs]deps}
whitelist_externals =
make
commands =
sphinx-build -W -b latex doc/source doc/build/pdf
make -C doc/build/pdf
[testenv:releasenotes] [testenv:releasenotes]
basepython = python3 basepython = python3
deps = deps =