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