From 1a7f765d5cade66dde10ade9b46c49c9a354d696 Mon Sep 17 00:00:00 2001 From: Kaifeng Wang Date: Fri, 14 Jun 2019 11:55:26 +0800 Subject: [PATCH] Build pdf doc The is one of community goals that each project could produce a single PDF file. The pdf should be in the output of openstack-tox-docs job. TeX packages are required to build PDF locally, following is recommended: * inkscape * texlive-latex-base * texlive-latex-extra * texlive-fonts-recommended More about the goal: https://governance.openstack.org/tc/goals/train/pdf-doc-generation.html https://etherpad.openstack.org/p/train-pdf-support-goal https://etherpad.openstack.org/p/pdf-goal-train-common-problems Change-Id: I874f5428f87f19eaf5fa15fa25f55a735e17967d --- doc/source/conf.py | 3 ++- requirements.txt | 2 +- tox.ini | 6 ++++++ 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/doc/source/conf.py b/doc/source/conf.py index 9b7f23b..4bfc45b 100755 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -83,9 +83,10 @@ htmlhelp_basename = '%sdoc' % project # Grouping the document tree into LaTeX files. List of tuples # (source start file, target name, title, author, documentclass # [howto/manual]). + latex_documents = [ ('index', - '%s.tex' % project, + 'doc-ironic-inspector-specs.tex', project, u'OpenStack Ironic Inspector Team', 'manual'), ] diff --git a/requirements.txt b/requirements.txt index 583e1c2..60ae463 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,5 +1,5 @@ pbr!=2.1.0,>=2.0.0 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,>=1.6.2;python_version>='3.4' # BSD -openstackdocstheme>=1.18.1 # Apache-2.0 +openstackdocstheme>=1.20.0 # Apache-2.0 yasfb>=0.5.1 diff --git a/tox.ini b/tox.ini index 6180e74..ed882d5 100644 --- a/tox.ini +++ b/tox.ini @@ -21,6 +21,12 @@ commands = basepython = python3 commands = sphinx-build -W -b html doc/source doc/build/html +[testenv:pdf-docs] +basepython = python3 +whitelist_externals = make +commands = sphinx-build -W -b latex doc/source doc/build/pdf + make -C doc/build/pdf + [testenv:spelling] basepython = python3 deps =