|
17 | 17 | import subprocess
|
18 | 18 | from typing import Any, Dict
|
19 | 19 |
|
20 |
| -sys.path.insert(0, os.path.abspath('.')) |
21 |
| -sys.path.insert(0, os.path.abspath('../')) |
22 |
| -from pystac.version import __version__, STACVersion |
| 20 | +sys.path.insert(0, os.path.abspath(".")) |
| 21 | +sys.path.insert(0, os.path.abspath("../")) |
| 22 | +from pystac.version import __version__, STACVersion # noqa:E402 |
23 | 23 |
|
24 |
| -git_branch = subprocess.check_output(['git', |
25 |
| - 'rev-parse', |
26 |
| - '--abbrev-ref', |
27 |
| - 'HEAD']) \ |
28 |
| - .decode("utf-8") \ |
29 |
| - .strip() |
| 24 | +git_branch = ( |
| 25 | + subprocess.check_output(["git", "rev-parse", "--abbrev-ref", "HEAD"]) |
| 26 | + .decode("utf-8") |
| 27 | + .strip() |
| 28 | +) |
30 | 29 |
|
31 | 30 | # -- Project information -----------------------------------------------------
|
32 | 31 |
|
33 |
| -project = 'pystac' |
34 |
| -copyright = '2019, Azavea' |
35 |
| -author = 'stac-utils' |
| 32 | +project = "pystac" |
| 33 | +copyright = "2019, Azavea" |
| 34 | +author = "stac-utils" |
36 | 35 |
|
37 | 36 | # The short X.Y version
|
38 | 37 | version = __version__
|
|
50 | 49 | # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
|
51 | 50 | # ones.
|
52 | 51 | extensions = [
|
53 |
| - 'sphinx.ext.autodoc', |
54 |
| - 'sphinx.ext.viewcode', |
55 |
| - 'sphinx.ext.intersphinx', |
56 |
| - 'sphinx.ext.napoleon', |
57 |
| - 'sphinx.ext.githubpages', |
58 |
| - 'sphinx.ext.extlinks', |
59 |
| - 'sphinxcontrib.fulltoc', |
60 |
| - 'nbsphinx' |
| 52 | + "sphinx.ext.autodoc", |
| 53 | + "sphinx.ext.viewcode", |
| 54 | + "sphinx.ext.intersphinx", |
| 55 | + "sphinx.ext.napoleon", |
| 56 | + "sphinx.ext.githubpages", |
| 57 | + "sphinx.ext.extlinks", |
| 58 | + "sphinxcontrib.fulltoc", |
| 59 | + "nbsphinx", |
61 | 60 | ]
|
62 | 61 |
|
63 | 62 | extlinks = {
|
64 |
| - 'tutorial': ('https://github.com/stac-utils/pystac/' |
65 |
| - 'tree/{}/docs/tutorials/%s'.format(git_branch), 'tutorial'), |
66 |
| - 'stac-spec': ('https://github.com/radiantearth/stac-spec/tree/' |
67 |
| - 'v{}/%s'.format(STACVersion.DEFAULT_STAC_VERSION), 'path'), |
68 |
| - 'stac-ext': ('https://github.com/stac-extensions/%s', '%s extension') |
| 63 | + "tutorial": ( |
| 64 | + "https://github.com/stac-utils/pystac/" |
| 65 | + "tree/{}/docs/tutorials/%s".format(git_branch), |
| 66 | + "tutorial", |
| 67 | + ), |
| 68 | + "stac-spec": ( |
| 69 | + "https://github.com/radiantearth/stac-spec/tree/" |
| 70 | + "v{}/%s".format(STACVersion.DEFAULT_STAC_VERSION), |
| 71 | + "path", |
| 72 | + ), |
| 73 | + "stac-ext": ("https://github.com/stac-extensions/%s", "%s extension"), |
69 | 74 | }
|
70 | 75 |
|
71 | 76 | # Add any paths that contain templates here, relative to this directory.
|
72 |
| -templates_path = ['_templates'] |
| 77 | +templates_path = ["_templates"] |
73 | 78 |
|
74 | 79 | # The suffix(es) of source filenames.
|
75 | 80 | # You can specify multiple suffix as a list of string:
|
76 | 81 | #
|
77 | 82 | # source_suffix = ['.rst', '.md']
|
78 |
| -source_suffix = '.rst' |
| 83 | +source_suffix = ".rst" |
79 | 84 |
|
80 | 85 | # The master toctree document.
|
81 |
| -master_doc = 'index' |
| 86 | +master_doc = "index" |
82 | 87 |
|
83 | 88 | # The language for content autogenerated by Sphinx. Refer to documentation
|
84 | 89 | # for a list of supported languages.
|
|
90 | 95 | # List of patterns, relative to source directory, that match files and
|
91 | 96 | # directories to ignore when looking for source files.
|
92 | 97 | # This pattern also affects html_static_path and html_extra_path.
|
93 |
| -exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store', '**.ipynb_checkpoints'] |
| 98 | +exclude_patterns = ["_build", "Thumbs.db", ".DS_Store", "**.ipynb_checkpoints"] |
94 | 99 |
|
95 | 100 | # The name of the Pygments (syntax highlighting) style to use.
|
96 | 101 | pygments_style = None
|
|
101 | 106 | # The theme to use for HTML and HTML Help pages. See the documentation for
|
102 | 107 | # a list of builtin themes.
|
103 | 108 | #
|
104 |
| -html_theme = 'alabaster' |
| 109 | +html_theme = "alabaster" |
105 | 110 |
|
106 | 111 | # Theme options are theme-specific and customize the look and feel of a theme
|
107 | 112 | # further. For a list of options available for each theme, see the
|
|
119 | 124 | # Add any paths that contain custom static files (such as style sheets) here,
|
120 | 125 | # relative to this directory. They are copied after the builtin static files,
|
121 | 126 | # so a file named "default.css" will overwrite the builtin "default.css".
|
122 |
| -#html_static_path = ['_static'] |
| 127 | +# html_static_path = ['_static'] |
123 | 128 |
|
124 | 129 | # Custom sidebar templates, must be a dictionary that maps document names
|
125 | 130 | # to template names.
|
|
135 | 140 | # -- Options for HTMLHelp output ---------------------------------------------
|
136 | 141 |
|
137 | 142 | # Output file base name for HTML help builder.
|
138 |
| -htmlhelp_basename = 'pystacdoc' |
| 143 | +htmlhelp_basename = "pystacdoc" |
139 | 144 |
|
140 | 145 |
|
141 | 146 | # -- Options for LaTeX output ------------------------------------------------
|
|
144 | 149 | # The paper size ('letterpaper' or 'a4paper').
|
145 | 150 | #
|
146 | 151 | # 'papersize': 'letterpaper',
|
147 |
| - |
148 | 152 | # The font size ('10pt', '11pt' or '12pt').
|
149 | 153 | #
|
150 | 154 | # 'pointsize': '10pt',
|
151 |
| - |
152 | 155 | # Additional stuff for the LaTeX preamble.
|
153 | 156 | #
|
154 | 157 | # 'preamble': '',
|
155 |
| - |
156 | 158 | # Latex figure (float) alignment
|
157 | 159 | #
|
158 | 160 | # 'figure_align': 'htbp',
|
|
162 | 164 | # (source start file, target name, title,
|
163 | 165 | # author, documentclass [howto, manual, or own class]).
|
164 | 166 | latex_documents = [
|
165 |
| - (master_doc, 'pystac.tex', 'pystac Documentation', |
166 |
| - 'stac-utils', 'manual'), |
| 167 | + (master_doc, "pystac.tex", "pystac Documentation", "stac-utils", "manual"), |
167 | 168 | ]
|
168 | 169 |
|
169 | 170 |
|
170 | 171 | # -- Options for manual page output ------------------------------------------
|
171 | 172 |
|
172 | 173 | # One entry per manual page. List of tuples
|
173 | 174 | # (source start file, name, description, authors, manual section).
|
174 |
| -man_pages = [ |
175 |
| - (master_doc, 'pystac', 'pystac Documentation', |
176 |
| - [author], 1) |
177 |
| -] |
| 175 | +man_pages = [(master_doc, "pystac", "pystac Documentation", [author], 1)] |
178 | 176 |
|
179 | 177 |
|
180 | 178 | # -- Options for Texinfo output ----------------------------------------------
|
|
183 | 181 | # (source start file, target name, title, author,
|
184 | 182 | # dir menu entry, description, category)
|
185 | 183 | texinfo_documents = [
|
186 |
| - (master_doc, 'pystac', 'pystac Documentation', |
187 |
| - author, 'pystac', 'Python library for SpatioTemporal Asset Catalogs (STAC).', |
188 |
| - 'Miscellaneous'), |
| 184 | + ( |
| 185 | + master_doc, |
| 186 | + "pystac", |
| 187 | + "pystac Documentation", |
| 188 | + author, |
| 189 | + "pystac", |
| 190 | + "Python library for SpatioTemporal Asset Catalogs (STAC).", |
| 191 | + "Miscellaneous", |
| 192 | + ), |
189 | 193 | ]
|
190 | 194 |
|
191 | 195 |
|
|
204 | 208 | # epub_uid = ''
|
205 | 209 |
|
206 | 210 | # A list of files that should not be packed into the epub file.
|
207 |
| -epub_exclude_files = ['search.html'] |
| 211 | +epub_exclude_files = ["search.html"] |
208 | 212 |
|
209 | 213 |
|
210 | 214 | # -- Extension configuration -------------------------------------------------
|
211 | 215 |
|
212 | 216 | intersphinx_mapping = {
|
213 |
| - 'python': ('https://docs.python.org/3', None), |
| 217 | + "python": ("https://docs.python.org/3", None), |
214 | 218 | }
|
0 commit comments