Repository navigation
doc: make canonical URLs absolute and list root pages in llms.txt - #39913
Merged
Merged
Conversation
This was referenced Oct 16, 2026
The Markdown templates told the website build from the skill bundle with two different base-path checks, and the HTML templates told builds with a Markdown tree from self-managed builds with a substring match repeated in two places. markdown-on-website.html and site-has-markdown.html now own those two decisions, and every caller uses them. The production HTML and Markdown builds and the skill bundle are byte-identical before and after. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
With the bare-path baseURL "/docs", .Permalink has no scheme or host, so both were paths. og:url must be an absolute URL, and an absolute canonical leaves nothing for a crawler to resolve. Both now use the absolute-permalink partial that the sitemap uses. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
The pages at the docs root, License and Support, were published in an about/llms.txt index, a directory that holds nothing else, since no "about" section exists. The root llms.txt now lists them itself, under their sidebar header, and about/llms.txt is no longer generated. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
doc/user/layouts/sitemap.xml copies Hugo's built-in sitemap template, so a Hugo upgrade can leave it behind the version it overrides. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
bosconi
force-pushed
the
jc/docs-agent-followups
branch
from
October 16, 2026 23:57
d8b3b3e to
a3189ae
Compare
bosconi
marked this pull request as ready for review
October 17, 2026 00:12
antiguru
approved these changes
Oct 17, 2026
antiguru
left a comment
Member
There was a problem hiding this comment.
Thank you!
Some nits: markdown-on-website could have a more specific name markdown-links-absolute.
The partial decides whether links in the Markdown output must be absolute URLs, so name it for that, per review. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Member
Author
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Follow-ups promised in review of #39470.
Part of: EDU-101
What changed
og:urlare absolute.head.htmlprinted.Permalinkfor both, which under--baseURL /docsis a path such as/docs/sql/create-source/.og:urlmust be an absolute URL. Both now use theabsolute-permalinkpartial that the sitemap already uses.llms.txt. License and Support have no section, so they were published inabout/llms.txt, a directory with nothing else in it. The root index now lists them under their sidebar header ("About"), andabout/llms.txtis no longer generated. The root index's orienting note says that pages outside any section follow the section list.bin/gen-claude-skillbundle, where root-relative links name bundle directories?markdown-link-urlcheckedne Path "/", andmarkdown-bodychecked for a non-empty trimmed path.markdown-links-absolute.htmlnow owns this. The two checks only disagreed for a host-only--baseURL, which no build uses.self-managed-docs/*branches build the HTML alone.has-markdownandindex.llmstxt.txteach matched "self-managed" in the base path.site-has-markdown.htmlnow owns this, andhas-markdowncalls it.ci/builder/Dockerfilesays to comparedoc/user/layouts/sitemap.xmlwith the built-in template on each Hugo bump. This changes the ci-builder image hash, so CI rebuilds the builder image for this PR.Verification
Built with Hugo 0.152.2 before and after: the production HTML and Markdown passes (
--baseURL /docs), the skill bundle (no--baseURL, asbin/gen-claude-skillruns it), the preview passes, thelint-docs.shpasses with a host in the base URL, and a self-managed HTML build. Each build was byte-identical across two runs of the same commit, so every difference below comes from this PR.og:urlandcanonical, on all 570 pages, and all 570 of each are now absolute. Production useshttps://materialize.com/docs/..., self-managedhttps://materialize.com/docs/self-managed/<version>/..., previewhttps://preview.materialize.com/materialize/<PR>/.... The lint build's HTML is unchanged, because its base URL already has a host.llms.txtchanges as described above in the production, preview and lint builds. The self-managed build still publishes none.check-docs-markdown.py --fail-on-linkspasses on the production Markdown, andtest_check_docs_markdown.pypasses.Not changed: the 542 alias pages, rendered by
layouts/alias.html, keep a path-only canonical. In production,website.shreplaces each with an S3 redirect, so their HTML is never served.🤖 Generated with Claude Code