Browse Source

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: Ib7379bb5066ede1956424dc92cf302ec22053f21
changes/69/680369/2
Kaifeng Wang 1 week ago
parent
commit
c28503f70e
4 changed files with 16 additions and 11 deletions
  1. 1
    1
      doc/requirements.txt
  2. 6
    9
      doc/source/conf.py
  3. 1
    1
      lower-constraints.txt
  4. 8
    0
      tox.ini

+ 1
- 1
doc/requirements.txt View File

@@ -1,6 +1,6 @@
1 1
 sphinx!=1.6.6,!=1.6.7,>=1.6.2,<2.0.0;python_version=='2.7' # BSD
2 2
 sphinx!=1.6.6,!=1.6.7,!=2.1.0,>=1.6.2;python_version>='3.4' # BSD
3
-openstackdocstheme>=1.18.1 # Apache-2.0
3
+openstackdocstheme>=1.20.0 # Apache-2.0
4 4
 reno>=2.5.0 # Apache-2.0
5 5
 testtools>=2.2.0 # MIT
6 6
 testrepository>=0.0.18 # Apache-2.0/BSD

+ 6
- 9
doc/source/conf.py View File

@@ -160,7 +160,6 @@ source_suffix = '.rst'
160 160
 master_doc = 'index'
161 161
 
162 162
 # General information about the project.
163
-project = u'ironic-ui'
164 163
 copyright = u'2016, OpenStack Foundation'
165 164
 
166 165
 
@@ -185,22 +184,20 @@ html_theme = 'openstackdocs'
185 184
 
186 185
 # openstackdocstheme options
187 186
 repository_name = 'openstack/ironic-ui'
188
-bug_project = 'ironic-ui'
189
-bug_tag = ''
190
-
191
-# Must set this variable to include year, month, day, hours, and minutes.
192
-html_last_updated_fmt = '%Y-%m-%d %H:%M'
187
+use_storyboard = True
193 188
 
194 189
 # Output file base name for HTML help builder.
195
-htmlhelp_basename = '%sdoc' % project
190
+htmlhelp_basename = 'ironic-uidoc'
191
+
192
+latex_use_xindy = False
196 193
 
197 194
 # Grouping the document tree into LaTeX files. List of tuples
198 195
 # (source start file, target name, title, author, documentclass
199 196
 # [howto/manual]).
200 197
 latex_documents = [
201 198
     ('index',
202
-     '%s.tex' % project,
203
-     u'%s Documentation' % project,
199
+     'doc-ironic-ui.tex',
200
+     u'Ironic UI Documentation',
204 201
      u'OpenStack Foundation', 'manual'),
205 202
 ]
206 203
 

+ 1
- 1
lower-constraints.txt View File

@@ -46,7 +46,7 @@ msgpack==0.5.6
46 46
 munch==2.2.0
47 47
 netaddr==0.7.19
48 48
 netifaces==0.10.6
49
-openstackdocstheme==1.18.1
49
+openstackdocstheme==1.20.0
50 50
 openstacksdk==0.12.0
51 51
 os-client-config==1.29.0
52 52
 os-service-types==1.2.0

+ 8
- 0
tox.ini View File

@@ -55,6 +55,14 @@ deps =
55 55
 commands =
56 56
   sphinx-build -W -b html doc/source doc/build/html
57 57
 
58
+[testenv:pdf-docs]
59
+basepython = python3
60
+deps = {[testenv:docs]deps}
61
+whitelist_externals = make
62
+commands =
63
+  sphinx-build -W -b latex doc/source doc/build/pdf
64
+  make -C doc/build/pdf
65
+
58 66
 [testenv:debug]
59 67
 basepython = python3
60 68
 commands = oslo_debug_helper -t ironic_ui/test/tests {posargs}

Loading…
Cancel
Save