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