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