|
15 | 15 |
|
16 | 16 | import sys |
17 | 17 | import os |
18 | | -import shlex |
19 | 18 | import subprocess |
| 19 | +import sphinx_bootstrap_theme |
| 20 | +from recommonmark.parser import CommonMarkParser |
| 21 | +from recommonmark.transform import AutoStructify |
20 | 22 |
|
21 | 23 | sys.path.append(os.path.join(os.path.dirname(__file__), '..')) |
22 | | -from git_version import git_version |
| 24 | +from git_version import git_version # noqa: E402 |
23 | 25 |
|
24 | 26 | on_rtd = os.environ.get('READTHEDOCS', None) == 'True' |
25 | 27 |
|
26 | 28 | if on_rtd: |
27 | 29 | subprocess.check_call([sys.executable, '-m', 'pip', 'install', 'sphinx_bootstrap_theme', 'recommonmark', 'evdev']) |
28 | 30 |
|
29 | | -import sphinx_bootstrap_theme |
30 | | -from recommonmark.parser import CommonMarkParser |
31 | | -from recommonmark.transform import AutoStructify |
32 | | - |
33 | 31 | # If extensions (or modules to document with autodoc) are in another directory, |
34 | 32 | # add these directories to sys.path here. If the directory is relative to the |
35 | 33 | # documentation root, use os.path.abspath to make it absolute, like shown here. |
36 | | -#sys.path.insert(0, os.path.abspath('.')) |
| 34 | +# sys.path.insert(0, os.path.abspath('.')) |
37 | 35 |
|
38 | 36 | # -- General configuration ------------------------------------------------ |
39 | 37 |
|
40 | 38 | # If your documentation needs a minimal Sphinx version, state it here. |
41 | | -#needs_sphinx = '1.0' |
| 39 | +# needs_sphinx = '1.0' |
42 | 40 |
|
43 | 41 | # Add any Sphinx extension module names here, as strings. They can be |
44 | 42 | # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom |
|
61 | 59 | source_suffix = ['.rst', '.md'] |
62 | 60 |
|
63 | 61 | # The encoding of source files. |
64 | | -#source_encoding = 'utf-8-sig' |
| 62 | +# source_encoding = 'utf-8-sig' |
65 | 63 |
|
66 | 64 | # The master toctree document. |
67 | 65 | master_doc = 'index' |
|
89 | 87 |
|
90 | 88 | # There are two options for replacing |today|: either, you set today to some |
91 | 89 | # non-false value, then it is used: |
92 | | -#today = '' |
| 90 | +# today = '' |
93 | 91 | # Else, today_fmt is used as the format for a strftime call. |
94 | | -#today_fmt = '%B %d, %Y' |
| 92 | +# today_fmt = '%B %d, %Y' |
95 | 93 |
|
96 | 94 | # List of patterns, relative to source directory, that match files and |
97 | 95 | # directories to ignore when looking for source files. |
98 | 96 | exclude_patterns = ['_build'] |
99 | 97 |
|
100 | 98 | # The reST default role (used for this markup: `text`) to use for all |
101 | 99 | # documents. |
102 | | -#default_role = None |
| 100 | +# default_role = None |
103 | 101 |
|
104 | 102 | # If true, '()' will be appended to :func: etc. cross-reference text. |
105 | | -#add_function_parentheses = True |
| 103 | +# add_function_parentheses = True |
106 | 104 |
|
107 | 105 | # If true, the current module name will be prepended to all description |
108 | 106 | # unit titles (such as .. function::). |
109 | | -#add_module_names = True |
| 107 | +# add_module_names = True |
110 | 108 |
|
111 | 109 | # If true, sectionauthor and moduleauthor directives will be shown in the |
112 | 110 | # output. They are ignored by default. |
113 | | -#show_authors = False |
| 111 | +# show_authors = False |
114 | 112 |
|
115 | 113 | # The name of the Pygments (syntax highlighting) style to use. |
116 | 114 | pygments_style = 'sphinx' |
117 | 115 |
|
118 | 116 | # A list of ignored prefixes for module index sorting. |
119 | | -#modindex_common_prefix = [] |
| 117 | +# modindex_common_prefix = [] |
120 | 118 |
|
121 | 119 | # If true, keep warnings as "system message" paragraphs in the built documents. |
122 | | -#keep_warnings = False |
| 120 | +# keep_warnings = False |
123 | 121 |
|
124 | 122 | # If true, `todo` and `todoList` produce output, else they produce nothing. |
125 | 123 | todo_include_todos = False |
|
138 | 136 | # Theme options are theme-specific and customize the look and feel of a theme |
139 | 137 | # further. For a list of options available for each theme, see the |
140 | 138 | # documentation. |
141 | | -#html_theme_options = {} |
| 139 | +# html_theme_options = {} |
142 | 140 |
|
143 | 141 | # Add any paths that contain custom themes here, relative to this directory. |
144 | | -#html_theme_path = [] |
| 142 | +# html_theme_path = [] |
145 | 143 |
|
146 | 144 | # The name for this set of Sphinx documents. If None, it defaults to |
147 | 145 | # "<project> v<release> documentation". |
148 | | -#html_title = None |
| 146 | +# html_title = None |
149 | 147 |
|
150 | 148 | # A shorter title for the navigation bar. Default is the same as html_title. |
151 | | -#html_short_title = None |
| 149 | +# html_short_title = None |
152 | 150 |
|
153 | 151 | # The name of an image file (relative to this directory) to place at the top |
154 | 152 | # of the sidebar. |
155 | | -#html_logo = None |
| 153 | +# html_logo = None |
156 | 154 |
|
157 | 155 | # The name of an image file (within the static path) to use as favicon of the |
158 | 156 | # docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32 |
159 | 157 | # pixels large. |
160 | | -#html_favicon = None |
| 158 | +# html_favicon = None |
161 | 159 |
|
162 | 160 | # Add any paths that contain custom static files (such as style sheets) here, |
163 | 161 | # relative to this directory. They are copied after the builtin static files, |
|
167 | 165 | # Add any extra paths that contain custom files (such as robots.txt or |
168 | 166 | # .htaccess) here, relative to this directory. These files are copied |
169 | 167 | # directly to the root of the documentation. |
170 | | -#html_extra_path = [] |
| 168 | +# html_extra_path = [] |
171 | 169 |
|
172 | 170 | # If not '', a 'Last updated on:' timestamp is inserted at every page bottom, |
173 | 171 | # using the given strftime format. |
174 | | -#html_last_updated_fmt = '%b %d, %Y' |
| 172 | +# html_last_updated_fmt = '%b %d, %Y' |
175 | 173 |
|
176 | 174 | # If true, SmartyPants will be used to convert quotes and dashes to |
177 | 175 | # typographically correct entities. |
178 | | -#html_use_smartypants = True |
| 176 | +# html_use_smartypants = True |
179 | 177 |
|
180 | 178 | # Custom sidebar templates, maps document names to template names. |
181 | | -#html_sidebars = {} |
| 179 | +# html_sidebars = {} |
182 | 180 |
|
183 | 181 | # Additional templates that should be rendered to pages, maps page names to |
184 | 182 | # template names. |
185 | | -#html_additional_pages = {} |
| 183 | +# html_additional_pages = {} |
186 | 184 |
|
187 | 185 | # If false, no module index is generated. |
188 | | -#html_domain_indices = True |
| 186 | +# html_domain_indices = True |
189 | 187 |
|
190 | 188 | # If false, no index is generated. |
191 | | -#html_use_index = True |
| 189 | +# html_use_index = True |
192 | 190 |
|
193 | 191 | # If true, the index is split into individual pages for each letter. |
194 | | -#html_split_index = False |
| 192 | +# html_split_index = False |
195 | 193 |
|
196 | 194 | # If true, links to the reST sources are added to the pages. |
197 | | -#html_show_sourcelink = True |
| 195 | +# html_show_sourcelink = True |
198 | 196 |
|
199 | 197 | # If true, "Created using Sphinx" is shown in the HTML footer. Default is True. |
200 | | -#html_show_sphinx = True |
| 198 | +# html_show_sphinx = True |
201 | 199 |
|
202 | 200 | # If true, "(C) Copyright ..." is shown in the HTML footer. Default is True. |
203 | | -#html_show_copyright = True |
| 201 | +# html_show_copyright = True |
204 | 202 |
|
205 | 203 | # If true, an OpenSearch description file will be output, and all pages will |
206 | 204 | # contain a <link> tag referring to it. The value of this option must be the |
207 | 205 | # base URL from which the finished HTML is served. |
208 | | -#html_use_opensearch = '' |
| 206 | +# html_use_opensearch = '' |
209 | 207 |
|
210 | 208 | # This is the file name suffix for HTML files (e.g. ".xhtml"). |
211 | | -#html_file_suffix = None |
| 209 | +# html_file_suffix = None |
212 | 210 |
|
213 | 211 | # Language to be used for generating the HTML full-text search index. |
214 | 212 | # Sphinx supports the following languages: |
215 | 213 | # 'da', 'de', 'en', 'es', 'fi', 'fr', 'h', 'it', 'ja' |
216 | 214 | # 'nl', 'no', 'pt', 'ro', 'r', 'sv', 'tr' |
217 | | -#html_search_language = 'en' |
| 215 | +# html_search_language = 'en' |
218 | 216 |
|
219 | 217 | # A dictionary with options for the search language support, empty by default. |
220 | 218 | # Now only 'ja' uses this config value |
221 | | -#html_search_options = {'type': 'default'} |
| 219 | +# html_search_options = {'type': 'default'} |
222 | 220 |
|
223 | 221 | # The name of a javascript file (relative to the configuration directory) that |
224 | 222 | # implements a search results scorer. If empty, the default will be used. |
225 | | -#html_search_scorer = 'scorer.js' |
| 223 | +# html_search_scorer = 'scorer.js' |
226 | 224 |
|
227 | 225 | # Output file base name for HTML help builder. |
228 | 226 | htmlhelp_basename = 'python-ev3devdoc' |
|
231 | 229 |
|
232 | 230 | latex_elements = { |
233 | 231 | # The paper size ('letterpaper' or 'a4paper'). |
234 | | - #'papersize': 'letterpaper', |
| 232 | + # 'papersize': 'letterpaper', |
235 | 233 |
|
236 | 234 | # The font size ('10pt', '11pt' or '12pt'). |
237 | | - #'pointsize': '10pt', |
| 235 | + # 'pointsize': '10pt', |
238 | 236 |
|
239 | 237 | # Additional stuff for the LaTeX preamble. |
240 | | - #'preamble': '', |
| 238 | + # 'preamble': '', |
241 | 239 |
|
242 | 240 | # Latex figure (float) alignment |
243 | | - #'figure_align': 'htbp', |
| 241 | + # 'figure_align': 'htbp', |
244 | 242 | } |
245 | 243 |
|
246 | 244 | # Grouping the document tree into LaTeX files. List of tuples |
|
252 | 250 |
|
253 | 251 | # The name of an image file (relative to this directory) to place at the top of |
254 | 252 | # the title page. |
255 | | -#latex_logo = None |
| 253 | +# latex_logo = None |
256 | 254 |
|
257 | 255 | # For "manual" documents, if this is true, then toplevel headings are parts, |
258 | 256 | # not chapters. |
259 | | -#latex_use_parts = False |
| 257 | +# latex_use_parts = False |
260 | 258 |
|
261 | 259 | # If true, show page references after internal links. |
262 | | -#latex_show_pagerefs = False |
| 260 | +# latex_show_pagerefs = False |
263 | 261 |
|
264 | 262 | # If true, show URL addresses after external links. |
265 | | -#latex_show_urls = False |
| 263 | +# latex_show_urls = False |
266 | 264 |
|
267 | 265 | # Documents to append as an appendix to all manuals. |
268 | | -#latex_appendices = [] |
| 266 | +# latex_appendices = [] |
269 | 267 |
|
270 | 268 | # If false, no module index is generated. |
271 | | -#latex_domain_indices = True |
| 269 | +# latex_domain_indices = True |
272 | 270 |
|
273 | 271 | # -- Options for manual page output --------------------------------------- |
274 | 272 |
|
|
277 | 275 | man_pages = [(master_doc, 'python-ev3dev', 'python-ev3dev Documentation', [author], 1)] |
278 | 276 |
|
279 | 277 | # If true, show URL addresses after external links. |
280 | | -#man_show_urls = False |
| 278 | +# man_show_urls = False |
281 | 279 |
|
282 | 280 | # -- Options for Texinfo output ------------------------------------------- |
283 | 281 |
|
|
290 | 288 | ] |
291 | 289 |
|
292 | 290 | # Documents to append as an appendix to all manuals. |
293 | | -#texinfo_appendices = [] |
| 291 | +# texinfo_appendices = [] |
294 | 292 |
|
295 | 293 | # If false, no module index is generated. |
296 | | -#texinfo_domain_indices = True |
| 294 | +# texinfo_domain_indices = True |
297 | 295 |
|
298 | 296 | # How to display URL addresses: 'footnote', 'no', or 'inline'. |
299 | | -#texinfo_show_urls = 'footnote' |
| 297 | +# texinfo_show_urls = 'footnote' |
300 | 298 |
|
301 | 299 | # If true, do not generate a @detailmenu in the "Top" node's menu. |
302 | | -#texinfo_no_detailmenu = False |
| 300 | +# texinfo_no_detailmenu = False |
303 | 301 |
|
304 | 302 | autodoc_member_order = 'bysource' |
305 | 303 |
|
|
0 commit comments