mirror of
https://github.com/beetbox/beets.git
synced 2025-12-06 08:39:17 +01:00
Take into account Sphinx updates in docs and release script
This commit is contained in:
parent
bcc91ffff5
commit
64b3481235
2 changed files with 7 additions and 4 deletions
|
|
@ -5,7 +5,7 @@ AUTHOR = "Adrian Sampson"
|
||||||
extensions = ["sphinx.ext.autodoc", "sphinx.ext.extlinks"]
|
extensions = ["sphinx.ext.autodoc", "sphinx.ext.extlinks"]
|
||||||
|
|
||||||
exclude_patterns = ["_build"]
|
exclude_patterns = ["_build"]
|
||||||
source_suffix = ".rst"
|
source_suffix = {".rst": "restructuredtext"}
|
||||||
master_doc = "index"
|
master_doc = "index"
|
||||||
|
|
||||||
project = "beets"
|
project = "beets"
|
||||||
|
|
@ -66,7 +66,7 @@ html_theme_options = {
|
||||||
"logo": {
|
"logo": {
|
||||||
"text": "beets",
|
"text": "beets",
|
||||||
},
|
},
|
||||||
"pygment_light_style": "bw",
|
"pygments_light_style": "bw",
|
||||||
}
|
}
|
||||||
html_title = "beets"
|
html_title = "beets"
|
||||||
html_logo = "_static/beets_logo_nobg.png"
|
html_logo = "_static/beets_logo_nobg.png"
|
||||||
|
|
|
||||||
|
|
@ -46,6 +46,8 @@ class Ref(NamedTuple):
|
||||||
Each line has the following structure:
|
Each line has the following structure:
|
||||||
<id> [optional title : ] <relative-url-path>
|
<id> [optional title : ] <relative-url-path>
|
||||||
|
|
||||||
|
See the output of
|
||||||
|
python -m sphinx.ext.intersphinx docs/_build/html/objects.inv
|
||||||
"""
|
"""
|
||||||
if len(line_parts := line.split(" ", 1)) == 1:
|
if len(line_parts := line.split(" ", 1)) == 1:
|
||||||
return cls(line, None, None)
|
return cls(line, None, None)
|
||||||
|
|
@ -82,10 +84,11 @@ def get_refs() -> dict[str, Ref]:
|
||||||
with redirect_stdout(captured_output):
|
with redirect_stdout(captured_output):
|
||||||
intersphinx.inspect_main([str(objects_filepath)])
|
intersphinx.inspect_main([str(objects_filepath)])
|
||||||
|
|
||||||
|
lines = captured_output.getvalue().replace("\t", " ").splitlines()
|
||||||
return {
|
return {
|
||||||
r.id: r
|
r.id: r
|
||||||
for ln in captured_output.getvalue().split("\n")
|
for ln in lines
|
||||||
if ln.startswith("\t") and (r := Ref.from_line(ln.strip()))
|
if ln.startswith(" ") and (r := Ref.from_line(ln.strip()))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue