Skip to content

Commit 8f3e168

Browse files
committed
Update conf.py to modern RTD requirements
1 parent db4eab9 commit 8f3e168

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

docs/conf.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,3 +32,13 @@
3232
autodoc_default_options = {"members": False, "maxdepth": 1}
3333

3434
autodoc_member_order = "groupwise"
35+
36+
37+
# Set canonical URL from the Read the Docs Domain
38+
html_baseurl = os.environ.get("READTHEDOCS_CANONICAL_URL", "")
39+
40+
# Tell Jinja2 templates the build is running on Read the Docs
41+
if os.environ.get("READTHEDOCS", "") == "True":
42+
if "html_context" not in globals():
43+
html_context = {}
44+
html_context["READTHEDOCS"] = True

0 commit comments

Comments
 (0)