blob: 5bbe2959a7a9ddb2e049e6c69de5c4f8c2dd7fc7 [file] [log] [blame]
Michael Johnson34139b02017-03-15 10:31:10 -07001# -*- coding: utf-8 -*-
2# Licensed under the Apache License, Version 2.0 (the "License");
3# you may not use this file except in compliance with the License.
4# You may obtain a copy of the License at
5#
6# http://www.apache.org/licenses/LICENSE-2.0
7#
8# Unless required by applicable law or agreed to in writing, software
9# distributed under the License is distributed on an "AS IS" BASIS,
10# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
11# implied.
12# See the License for the specific language governing permissions and
13# limitations under the License.
14
Michael Johnson791fefb2019-09-13 10:48:05 -070015import datetime
Michael Johnson34139b02017-03-15 10:31:10 -070016import os
17import sys
18
Jude Cross986e3f52017-07-24 14:57:20 -070019import openstackdocstheme
Jude Cross986e3f52017-07-24 14:57:20 -070020
Michael Johnson34139b02017-03-15 10:31:10 -070021sys.path.insert(0, os.path.abspath('../..'))
Jude Cross986e3f52017-07-24 14:57:20 -070022sys.path.insert(0, os.path.abspath('.'))
23
Michael Johnson34139b02017-03-15 10:31:10 -070024# -- General configuration ----------------------------------------------------
25
26# Add any Sphinx extension module names here, as strings. They can be
27# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
28extensions = [
29 'sphinx.ext.autodoc',
Jude Cross986e3f52017-07-24 14:57:20 -070030 'sphinx.ext.viewcode',
31 'openstackdocstheme',
Adam Harwell008dbec2018-05-16 00:35:36 -070032 'oslo_config.sphinxext',
Michael Johnson791fefb2019-09-13 10:48:05 -070033 'sphinxcontrib.apidoc',
34 'sphinxcontrib.rsvgconverter'
Michael Johnson34139b02017-03-15 10:31:10 -070035]
36
37# autodoc generation is a bit aggressive and a nuisance when doing heavy
38# text edit cycles.
39# execute "export SPHINX_DEBUG=1" in your terminal to disable
Jude Cross986e3f52017-07-24 14:57:20 -070040templates_path = ['_templates']
Michael Johnson34139b02017-03-15 10:31:10 -070041
42# The suffix of source filenames.
43source_suffix = '.rst'
44
45# The master toctree document.
46master_doc = 'index'
47
48# General information about the project.
49project = u'octavia-tempest-plugin'
Michael Johnson791fefb2019-09-13 10:48:05 -070050copyright = u'2017-2019, OpenStack Foundation'
51
52# The version info for the project you're documenting, acts as replacement for
53# |version| and |release|, also used in various other places throughout the
54# built documents.
55#
56# Version info
57from octavia_tempest_plugin.version import version_info as octavia_tempest_ver
58release = octavia_tempest_ver.release_string()
59# The short X.Y version.
60version = octavia_tempest_ver.version_string()
Michael Johnson34139b02017-03-15 10:31:10 -070061
62# If true, '()' will be appended to :func: etc. cross-reference text.
63add_function_parentheses = True
64
65# If true, the current module name will be prepended to all description
66# unit titles (such as .. function::).
Jude Cross986e3f52017-07-24 14:57:20 -070067add_module_names = False
Michael Johnson34139b02017-03-15 10:31:10 -070068
69# The name of the Pygments (syntax highlighting) style to use.
70pygments_style = 'sphinx'
71
Jude Cross986e3f52017-07-24 14:57:20 -070072# A list of ignored prefixes for module index sorting.
73modindex_common_prefix = ['octavia_tempest_plugin.']
74
Michael Johnson791fefb2019-09-13 10:48:05 -070075repository_name = 'openstack/octavia-tempest-plugin'
76bug_project = '910'
77bug_tag = 'docs'
78
79apidoc_output_dir = '_build/modules'
80apidoc_module_dir = '../../octavia_tempest_plugin'
81apidoc_excluded_paths = []
82
Michael Johnson34139b02017-03-15 10:31:10 -070083# -- Options for HTML output --------------------------------------------------
84
85# The theme to use for HTML and HTML Help pages. Major themes that come with
86# Sphinx are currently 'default' and 'sphinxdoc'.
87# html_theme_path = ["."]
88# html_theme = '_theme'
89# html_static_path = ['static']
90
Jude Cross986e3f52017-07-24 14:57:20 -070091html_theme = 'openstackdocs'
92
93html_last_updated_fmt = '%Y-%m-%d %H:%M'
94
Michael Johnson34139b02017-03-15 10:31:10 -070095# Output file base name for HTML help builder.
96htmlhelp_basename = '%sdoc' % project
97
Jude Cross986e3f52017-07-24 14:57:20 -070098# If false, no module index is generated.
99html_domain_indices = True
100
101# If false, no index is generated.
102html_use_index = True
103
Michael Johnson791fefb2019-09-13 10:48:05 -0700104# -- Options for LaTeX output -------------------------------------------------
105
106# Fix Unicode character for sphinx_feature_classification
107# Sphinx default latex engine (pdflatex) doesn't know much unicode
108latex_preamble = r"""
109\usepackage{newunicodechar}
110\newunicodechar{✖}{\sffamily X}
111\setcounter{tocdepth}{2}
112\authoraddress{\textcopyright %s OpenStack Foundation}
113""" % datetime.datetime.now().year
114
115latex_elements = {
116 # The paper size ('letterpaper' or 'a4paper').
117 # 'papersize': 'letterpaper',
118
119 # The font size ('10pt', '11pt' or '12pt').
120 # 'pointsize': '10pt',
121
122 # Additional stuff for the LaTeX preamble.
123 # openany: Skip blank pages in generated PDFs
124 'extraclassoptions': 'openany,oneside',
125 'makeindex': '',
126 'printindex': '',
127 'preamble': latex_preamble
128}
129
130# Disable usage of xindy https://bugzilla.redhat.com/show_bug.cgi?id=1643664
131# Some distros are missing xindy
132latex_use_xindy = False
133
134# Fix missing apostrophe
135smartquotes_excludes = {'builders': ['latex']}
136
Michael Johnson34139b02017-03-15 10:31:10 -0700137# Grouping the document tree into LaTeX files. List of tuples
138# (source start file, target name, title, author, documentclass
139# [howto/manual]).
Michael Johnson791fefb2019-09-13 10:48:05 -0700140latex_documents = [(
141 'index',
142 'doc-octavia-tempest-plugin.tex',
143 u'Octavia Tempest Plugin Documentation',
144 u'OpenStack Octavia Team',
145 'manual'
146)]
Michael Johnson34139b02017-03-15 10:31:10 -0700147
Michael Johnson791fefb2019-09-13 10:48:05 -0700148# The name of an image file (relative to this directory) to place at the top of
149# the title page.
150# latex_logo = None
Jude Cross986e3f52017-07-24 14:57:20 -0700151
Michael Johnson791fefb2019-09-13 10:48:05 -0700152# For "manual" documents, if this is true, then toplevel headings are parts,
153# not chapters.
154# latex_use_parts = False
Jude Cross986e3f52017-07-24 14:57:20 -0700155
Michael Johnson791fefb2019-09-13 10:48:05 -0700156# If true, show page references after internal links.
157# latex_show_pagerefs = False
158
159# If true, show URL addresses after external links.
160# latex_show_urls = False
161
162# Documents to append as an appendix to all manuals.
163# latex_appendices = []
164
165# If false, no module index is generated.
166latex_domain_indices = False