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