|
2 | 2 |
|
3 | 3 | import os
|
4 | 4 | import sys
|
5 |
| -sys.path.insert(0, os.path.abspath('..')) |
| 5 | + |
| 6 | +sys.path.insert(0, os.path.abspath("..")) |
6 | 7 |
|
7 | 8 | # -- General configuration ------------------------------------------------
|
8 | 9 |
|
9 | 10 | # Add any Sphinx extension module names here, as strings. They can be
|
10 | 11 | # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
|
11 | 12 | # ones.
|
12 | 13 | extensions = [
|
13 |
| - 'sphinx.ext.autodoc', |
14 |
| - 'sphinx.ext.intersphinx', |
15 |
| - 'sphinx.ext.napoleon', |
16 |
| - 'sphinx.ext.todo', |
| 14 | + "sphinx.ext.autodoc", |
| 15 | + "sphinx.ext.intersphinx", |
| 16 | + "sphinx.ext.napoleon", |
| 17 | + "sphinx.ext.todo", |
17 | 18 | ]
|
18 | 19 |
|
19 | 20 | # Uncomment the below if you use native CircuitPython modules such as
|
|
22 | 23 | autodoc_mock_imports = ["micropython", "microcontroller", "random", "adafruit_logging"]
|
23 | 24 |
|
24 | 25 |
|
25 |
| -intersphinx_mapping = {'python': ('https://docs.python.org/3.4', None),'CircuitPython': ('https://circuitpython.readthedocs.io/en/latest/', None)} |
| 26 | +intersphinx_mapping = { |
| 27 | + "python": ("https://docs.python.org/3.4", None), |
| 28 | + "CircuitPython": ("https://circuitpython.readthedocs.io/en/latest/", None), |
| 29 | +} |
26 | 30 |
|
27 | 31 | # Add any paths that contain templates here, relative to this directory.
|
28 |
| -templates_path = ['_templates'] |
| 32 | +templates_path = ["_templates"] |
29 | 33 |
|
30 |
| -source_suffix = '.rst' |
| 34 | +source_suffix = ".rst" |
31 | 35 |
|
32 | 36 | # The master toctree document.
|
33 |
| -master_doc = 'index' |
| 37 | +master_doc = "index" |
34 | 38 |
|
35 | 39 | # General information about the project.
|
36 |
| -project = u'Adafruit MiniMQTT Library' |
37 |
| -copyright = u'2019 Brent Rubell' |
38 |
| -author = u'Brent Rubell' |
| 40 | +project = u"Adafruit MiniMQTT Library" |
| 41 | +copyright = u"2019 Brent Rubell" |
| 42 | +author = u"Brent Rubell" |
39 | 43 |
|
40 | 44 | # The version info for the project you're documenting, acts as replacement for
|
41 | 45 | # |version| and |release|, also used in various other places throughout the
|
42 | 46 | # built documents.
|
43 | 47 | #
|
44 | 48 | # The short X.Y version.
|
45 |
| -version = u'1.0' |
| 49 | +version = u"1.0" |
46 | 50 | # The full version, including alpha/beta/rc tags.
|
47 |
| -release = u'1.0' |
| 51 | +release = u"1.0" |
48 | 52 |
|
49 | 53 | # The language for content autogenerated by Sphinx. Refer to documentation
|
50 | 54 | # for a list of supported languages.
|
|
56 | 60 | # List of patterns, relative to source directory, that match files and
|
57 | 61 | # directories to ignore when looking for source files.
|
58 | 62 | # This patterns also effect to html_static_path and html_extra_path
|
59 |
| -exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store', '.env', 'CODE_OF_CONDUCT.md'] |
| 63 | +exclude_patterns = ["_build", "Thumbs.db", ".DS_Store", ".env", "CODE_OF_CONDUCT.md"] |
60 | 64 |
|
61 | 65 | # The reST default role (used for this markup: `text`) to use for all
|
62 | 66 | # documents.
|
|
68 | 72 | add_function_parentheses = True
|
69 | 73 |
|
70 | 74 | # The name of the Pygments (syntax highlighting) style to use.
|
71 |
| -pygments_style = 'sphinx' |
| 75 | +pygments_style = "sphinx" |
72 | 76 |
|
73 | 77 | # If true, `todo` and `todoList` produce output, else they produce nothing.
|
74 | 78 | todo_include_todos = False
|
|
83 | 87 | # The theme to use for HTML and HTML Help pages. See the documentation for
|
84 | 88 | # a list of builtin themes.
|
85 | 89 | #
|
86 |
| -on_rtd = os.environ.get('READTHEDOCS', None) == 'True' |
| 90 | +on_rtd = os.environ.get("READTHEDOCS", None) == "True" |
87 | 91 |
|
88 | 92 | if not on_rtd: # only import and set the theme if we're building docs locally
|
89 | 93 | try:
|
90 | 94 | import sphinx_rtd_theme
|
91 |
| - html_theme = 'sphinx_rtd_theme' |
92 |
| - html_theme_path = [sphinx_rtd_theme.get_html_theme_path(), '.'] |
| 95 | + |
| 96 | + html_theme = "sphinx_rtd_theme" |
| 97 | + html_theme_path = [sphinx_rtd_theme.get_html_theme_path(), "."] |
93 | 98 | except:
|
94 |
| - html_theme = 'default' |
95 |
| - html_theme_path = ['.'] |
| 99 | + html_theme = "default" |
| 100 | + html_theme_path = ["."] |
96 | 101 | else:
|
97 |
| - html_theme_path = ['.'] |
| 102 | + html_theme_path = ["."] |
98 | 103 |
|
99 | 104 | # Add any paths that contain custom static files (such as style sheets) here,
|
100 | 105 | # relative to this directory. They are copied after the builtin static files,
|
101 | 106 | # so a file named "default.css" will overwrite the builtin "default.css".
|
102 |
| -html_static_path = ['_static'] |
| 107 | +html_static_path = ["_static"] |
103 | 108 |
|
104 | 109 | # The name of an image file (relative to this directory) to use as a favicon of
|
105 | 110 | # the docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32
|
106 | 111 | # pixels large.
|
107 | 112 | #
|
108 |
| -html_favicon = '_static/favicon.ico' |
| 113 | +html_favicon = "_static/favicon.ico" |
109 | 114 |
|
110 | 115 | # Output file base name for HTML help builder.
|
111 |
| -htmlhelp_basename = 'AdafruitMinimqttLibrarydoc' |
| 116 | +htmlhelp_basename = "AdafruitMinimqttLibrarydoc" |
112 | 117 |
|
113 | 118 | # -- Options for LaTeX output ---------------------------------------------
|
114 | 119 |
|
115 | 120 | latex_elements = {
|
116 |
| - # The paper size ('letterpaper' or 'a4paper'). |
117 |
| - # |
118 |
| - # 'papersize': 'letterpaper', |
119 |
| - |
120 |
| - # The font size ('10pt', '11pt' or '12pt'). |
121 |
| - # |
122 |
| - # 'pointsize': '10pt', |
123 |
| - |
124 |
| - # Additional stuff for the LaTeX preamble. |
125 |
| - # |
126 |
| - # 'preamble': '', |
127 |
| - |
128 |
| - # Latex figure (float) alignment |
129 |
| - # |
130 |
| - # 'figure_align': 'htbp', |
| 121 | + # The paper size ('letterpaper' or 'a4paper'). |
| 122 | + # |
| 123 | + # 'papersize': 'letterpaper', |
| 124 | + # The font size ('10pt', '11pt' or '12pt'). |
| 125 | + # |
| 126 | + # 'pointsize': '10pt', |
| 127 | + # Additional stuff for the LaTeX preamble. |
| 128 | + # |
| 129 | + # 'preamble': '', |
| 130 | + # Latex figure (float) alignment |
| 131 | + # |
| 132 | + # 'figure_align': 'htbp', |
131 | 133 | }
|
132 | 134 |
|
133 | 135 | # Grouping the document tree into LaTeX files. List of tuples
|
134 | 136 | # (source start file, target name, title,
|
135 | 137 | # author, documentclass [howto, manual, or own class]).
|
136 | 138 | latex_documents = [
|
137 |
| - (master_doc, 'AdafruitMiniMQTTLibrary.tex', u'AdafruitMiniMQTT Library Documentation', |
138 |
| - author, 'manual'), |
| 139 | + ( |
| 140 | + master_doc, |
| 141 | + "AdafruitMiniMQTTLibrary.tex", |
| 142 | + u"AdafruitMiniMQTT Library Documentation", |
| 143 | + author, |
| 144 | + "manual", |
| 145 | + ), |
139 | 146 | ]
|
140 | 147 |
|
141 | 148 | # -- Options for manual page output ---------------------------------------
|
142 | 149 |
|
143 | 150 | # One entry per manual page. List of tuples
|
144 | 151 | # (source start file, name, description, authors, manual section).
|
145 | 152 | man_pages = [
|
146 |
| - (master_doc, 'AdafruitMiniMQTTlibrary', u'Adafruit MiniMQTT Library Documentation', |
147 |
| - [author], 1) |
| 153 | + ( |
| 154 | + master_doc, |
| 155 | + "AdafruitMiniMQTTlibrary", |
| 156 | + u"Adafruit MiniMQTT Library Documentation", |
| 157 | + [author], |
| 158 | + 1, |
| 159 | + ) |
148 | 160 | ]
|
149 | 161 |
|
150 | 162 | # -- Options for Texinfo output -------------------------------------------
|
|
153 | 165 | # (source start file, target name, title, author,
|
154 | 166 | # dir menu entry, description, category)
|
155 | 167 | texinfo_documents = [
|
156 |
| - (master_doc, 'AdafruitMiniMQTTLibrary', u'Adafruit MiniMQTT Library Documentation', |
157 |
| - author, 'AdafruitMiniMQTTLibrary', 'One line description of project.', |
158 |
| - 'Miscellaneous'), |
| 168 | + ( |
| 169 | + master_doc, |
| 170 | + "AdafruitMiniMQTTLibrary", |
| 171 | + u"Adafruit MiniMQTT Library Documentation", |
| 172 | + author, |
| 173 | + "AdafruitMiniMQTTLibrary", |
| 174 | + "One line description of project.", |
| 175 | + "Miscellaneous", |
| 176 | + ), |
159 | 177 | ]
|
0 commit comments