Skip to content

Commit 110a90a

Browse files
imtherealnaskaDandandanclaudeviiryazhuqi-lucas
authored
feat: add sphinx-sitemap dependency and configuration for sitemap generation (apache#24332)
## Which issue does this PR close? - Part of apache#23258 ## What changes are included in this PR? There are 2 PR's for this issue. This one contains the changes for sitemap.xml - added the sphinx-sitemap build dependency. - enabled the sphinx_sitemap extension, set html_baseurl, and set sitemap_url_scheme = "{link}" ## Are these changes tested? Yes. Tested by building the docs and verifying the files getting generated in the build/ ## Are there any user-facing changes? No. --------- Signed-off-by: dependabot[bot] <[email protected]> Signed-off-by: Reid Kaufmann <[email protected]> Co-authored-by: Daniël Heres <[email protected]> Co-authored-by: Claude Opus 5 <[email protected]> Co-authored-by: Liang-Chi Hsieh <[email protected]> Co-authored-by: Qi Zhu <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: linfeng <[email protected]> Co-authored-by: anchor <[email protected]> Co-authored-by: codeAnqiang-ma <[email protected]> Co-authored-by: Adrian Garcia Badaracco <[email protected]> Co-authored-by: dentiny <[email protected]> Co-authored-by: kosiew <[email protected]> Co-authored-by: Tim Saucer <[email protected]> Co-authored-by: Subham Singhal <[email protected]> Co-authored-by: Goutam Adwant <[email protected]> Co-authored-by: Andrew Lamb <[email protected]> Co-authored-by: Burak Şen <[email protected]> Co-authored-by: RIchard Baah <[email protected]> Co-authored-by: rich-T-kid <[email protected]> Co-authored-by: sakshichitnis27 <[email protected]> Co-authored-by: Adam Gutglick <[email protected]> Co-authored-by: Alvaro Balbin <[email protected]> Co-authored-by: Reid Kaufmann <[email protected]> Co-authored-by: Andy Grove <[email protected]> Co-authored-by: kid <[email protected]> Co-authored-by: Nagato Yuzuru <[email protected]> Co-authored-by: Jamison-J <[email protected]> Co-authored-by: jiangzhen <[email protected]>
1 parent aff5850 commit 110a90a

3 files changed

Lines changed: 43 additions & 2 deletions

File tree

‎docs/pyproject.toml‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,5 @@ dependencies = [
1010
"maturin>=1.14.1,<2",
1111
"jinja2>=3.1.6,<4",
1212
"setuptools>=84.0.0,<85",
13+
"sphinx-sitemap>=2.9.0,<3",
1314
]

‎docs/source/conf.py‎

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@
5555
"myst_parser",
5656
"sphinx_reredirects",
5757
"rustdoc_trim",
58+
"sphinx_sitemap",
5859
]
5960

6061
source_suffix = {
@@ -89,8 +90,8 @@
8990

9091
html_theme_options = {
9192
"logo": {
92-
"image_light": "_static/images/original.svg",
93-
"image_dark": "_static/images/original_dark.svg",
93+
"image_light": "_static/images/original.svg",
94+
"image_dark": "_static/images/original_dark.svg",
9495
},
9596
"use_edit_page_button": True,
9697
"navbar_center": [],
@@ -113,6 +114,18 @@
113114
# resolve at the conventional URL `https://datafusion.apache.org/llms.txt`.
114115
html_extra_path = ["llms.txt"]
115116

117+
# Base URL of the published site. Required by sphinx-sitemap to build
118+
# absolute <loc> entries in the generated sitemap.xml.
119+
html_baseurl = "https://datafusion.apache.org/"
120+
121+
# The site is published as a single flat, single-language tree (see
122+
# .github/workflows/docs.yaml, which rsyncs docs/build/html/ straight to the
123+
# site root) — there is no /en/ or version path segment. Override
124+
# sphinx-sitemap's default "{lang}{version}{link}" scheme, which assumes a
125+
# Read the Docs-style multi-language/multi-version layout, so <loc> entries
126+
# match the real URLs instead of a nonexistent /en/... prefix.
127+
sitemap_url_scheme = "{link}"
128+
116129
html_logo = "_static/images/2x_bgwhite_original.png"
117130

118131
html_css_files = ["theme_overrides.css"]

‎uv.lock‎

Lines changed: 27 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)