Skip to content

Commit f85f880

Browse files
committed
Fix github_url?
1 parent b6e10f7 commit f85f880

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

docs/source/conf.py

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -45,9 +45,12 @@
4545
}
4646
html_context = {}
4747

48-
# sphinx_autodoc_defaultargs config
48+
# This prolog is useful for both sphinx_autodoc_defaultargs and the "Edit on
49+
# github" button
4950
rst_prolog = (
5051
"""
52+
:github_url: https://github.com/fractal-analytics-platform/fractal-tasks-core
53+
5154
.. |default| raw:: html
5255
5356
<div class="default-value-section">"""
@@ -58,7 +61,7 @@
5861
# Extensions to theme docs
5962
def setup(app):
6063

61-
# apidoc part
64+
# apidoc (see https://github.com/readthedocs/readthedocs.org/issues/1139)
6265
source_dir = Path(__file__).parent.absolute()
6366
package_dir = str(source_dir / "../../fractal_tasks_core")
6467
api_files_dir = str(source_dir / "api_files")
@@ -80,7 +83,6 @@ def setup(app):
8083
# What follows is taken from https://stackoverflow.com/a/68913808,
8184
# and used to remove each indented block following a line starting
8285
# with "Copyright"
83-
8486
what = None
8587

8688
def process(
@@ -94,7 +96,6 @@ def process(
9496
if what and what_ not in what:
9597
return
9698
orig_lines = lines[:]
97-
9899
ignoring = False
99100
new_lines = []
100101
for i, line in enumerate(orig_lines):
@@ -106,10 +107,8 @@ def process(
106107
# ignoring the indented region.
107108
if ignoring and line and not line.startswith(" "):
108109
ignoring = False
109-
110110
if not ignoring:
111111
new_lines.append(line)
112-
113112
lines[:] = new_lines
114113
# make sure there is a blank line at the end
115114
if lines and lines[-1]:

0 commit comments

Comments
 (0)