From 6f4e2a3b08b6dfbf4077fda225bc290b3960ee84 Mon Sep 17 00:00:00 2001 From: Kaifeng Wang Date: Fri, 14 Jun 2019 17:43:14 +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: I8ebbe9ea1bb2914061a8307f3edfabab166a3c38 --- doc/source/conf.py | 7 +++---- test-requirements.txt | 2 +- tox.ini | 6 ++++++ 3 files changed, 10 insertions(+), 5 deletions(-) diff --git a/doc/source/conf.py b/doc/source/conf.py index 114d4b0a..87b00c8e 100755 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -40,7 +40,6 @@ source_suffix = '.rst' master_doc = 'index' # General information about the project. -project = u'ironic-tempest-plugin' copyright = u'2016, OpenStack Foundation' # If true, '()' will be appended to :func: etc. cross-reference text. @@ -62,15 +61,15 @@ pygments_style = 'sphinx' html_theme = 'openstackdocs' # Output file base name for HTML help builder. -htmlhelp_basename = '%sdoc' % project +htmlhelp_basename = 'ironic-tempest-plugindoc' # 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, - u'%s Documentation' % project, + 'doc-ironic-tempest-plugin.tex', + u'Ironic Tempest Plugin Documentation', u'OpenStack Foundation', 'manual'), ] diff --git a/test-requirements.txt b/test-requirements.txt index b5667d28..fb97fc6e 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -6,6 +6,6 @@ hacking!=0.13.0,<0.14,>=0.12.0 # Apache-2.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 reno>=2.5.0 # Apache-2.0 diff --git a/tox.ini b/tox.ini index d686ee9e..c81582ce 100644 --- a/tox.ini +++ b/tox.ini @@ -28,6 +28,12 @@ commands = python setup.py test --coverage --testr-args='{posargs}' basepython = python3 commands = python setup.py build_sphinx +[testenv:pdf-docs] +basepython = python3 +whitelist_externals = make +commands = sphinx-build -b latex doc/source doc/build/pdf + make -C doc/build/pdf + [testenv:debug] basepython = python3 commands = oslo_debug_helper {posargs}