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