Skip to content

Commit db7ff49

Browse files
committed
docs/conf.py: updates per RTD docs
RTD is rolling out some changes. Per https://about.readthedocs.com/blog/2024/07/addons-by-default/, these are the changes we need to make. Signed-off-by: Jeff Squyres <jeff@squyres.com>
1 parent 11ff7f0 commit db7ff49

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

docs/conf.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,15 @@ def get_tarball_version(path, expr):
129129
if key in os.environ and os.environ[key] == 'True':
130130
print("OMPI: found ReadTheDocs build environment")
131131

132+
# Tell Jinja2 templates the build is running on Read the Docs
133+
if "html_context" not in globals():
134+
html_context = {}
135+
html_context["READTHEDOCS"] = True
136+
137+
# Define the canonical URL if you are using a custom domain on
138+
# Read the Docs
139+
html_baseurl = os.environ.get("READTHEDOCS_CANONICAL_URL", "")
140+
132141
rtd_v = os.environ['READTHEDOCS_VERSION']
133142
if os.environ['READTHEDOCS_VERSION_TYPE'] == 'external':
134143
# Make "release" be shorter than the full "ompi_ver" value.

0 commit comments

Comments
 (0)