Skip to content

docs: publish enhancement proposals on the documentation site - #701

Open
ArangoGutierrez wants to merge 2 commits into
NVIDIA:mainfrom
ArangoGutierrez:docs/698-publish-meps
Open

docs: publish enhancement proposals on the documentation site#701
ArangoGutierrez wants to merge 2 commits into
NVIDIA:mainfrom
ArangoGutierrez:docs/698-publish-meps

Conversation

@ArangoGutierrez

Copy link
Copy Markdown
Collaborator

Closes #698.

enhancements/meps/ holds two proposals with architecture diagrams that were
only reachable as links out to GitHub, because MkDocs publishes nothing outside
docs_dir.

Rather than move them, hack/sync-enhancement-docs.sh stages them into the
docs tree at build time. That keeps the MEP process where contributors expect
it: a new MEP lands in enhancements/ as it always has and appears on the site
with no second location to remember. The staged copy is gitignored and rebuilt
from scratch each run, so a stale copy cannot survive.

Every target that runs mkdocs depends on the sync, so make docs, make docs-serve and the exclusion guard all see the same tree, and CI needs no
special-casing.

One deviation from the issue as filed: deploy-pages.yaml does change. Its path
filters had to learn about enhancements/** and the sync script, because
without that a MEP edit would not rebuild the site and the published copy would
drift from the source.

docs/helm-chart.md previously linked MEP-0002 by absolute GitHub URL; it now
points at the in-site page.

make docs passes, and the MEP images are emitted into the built site rather
than only the pages that reference them.

MkDocs builds only what lives under docs_dir, so the MEPs in enhancements/
were reachable from the site only as links out to GitHub.

Moving them under docs/ would contradict the workflow in enhancements/README.md,
which tells contributors to add proposals under enhancements/meps/, and would
break every link already pointing there. The build takes a copy instead:
hack/sync-enhancement-docs.sh stages enhancements/ into docs/enhancements/
ahead of every mkdocs run, from docs-build, docs-serve and docs-check-exclusion
alike. The copy is gitignored and its destination is deleted on each run, so a
renamed or removed MEP cannot linger in a later build.

MEP text is written to render on GitHub, and MEP-0002 links three levels up into
pkg/ and tests/. Those targets do not exist inside docs_dir and mkdocs --strict
rejects them, so the copy step rewrites them to GitHub blob URLs and then checks
that the rewrite landed, which a silently non-matching sed would otherwise
surface much later as an opaque strict-mode failure. The originals keep their
relative form and stay correct on GitHub.

deploy-pages.yaml filters on paths, so a MEP-only change would have matched
nothing and never reached the site. enhancements/** and the sync script join the
filter; the build command itself is unchanged.

Closes NVIDIA#698

Signed-off-by: Carlos Eduardo Arango Gutierrez <eduardoa@nvidia.com>
@ArangoGutierrez
ArangoGutierrez marked this pull request as ready for review August 21, 2026 15:16
Comment thread .github/workflows/deploy-pages.yaml Outdated

name: Deploy documentation to Pages

# The MEPs are published from enhancements/, which `make docs` stages into the

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The comment is redundant for long-term readers, it's the agent trying to document what it's done for the specific task/chat.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fair, that was narrating the change rather than the code. Trimmed it to the part a later reader actually needs, which is that enhancements/ sits outside docs_dir so the filter only works because make docs stages it. Pushed as e78ad8b.

paths:
- "docs/**"
- "enhancements/**"
- "hack/sync-enhancement-docs.sh"

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I know ppl create these hack dirs but it's not it better to name it "tools"? 😃

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd keep hack/ here. hack/golang-version.sh is already in there and both variables.yaml and nvml-mock-e2e-go.yaml call it, and there's no tools/ yet, so renaming just this one would leave us with two script directories. Happy to move both in a separate change if you'd rather standardise on tools/.

Comment thread mkdocs.yml
- fake-gpu-operator: integrations/fake-gpu-operator.md
# These pages are a build-time copy of enhancements/ staged by
# hack/sync-enhancement-docs.sh; docs/enhancements/ is gitignored. Adding a MEP
# means adding it to enhancements/meps/ and listing it here.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would this be easier to move enhancements under docs? I feel like it may save us this back-and-forth with coding docs. We can make it a requirement to register new MEPs in this table of content.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Your instinct about the cost is right, though I think the script buys less than it looks like it does.

Registration is manual either way. The nav above lists every MEP by hand, and moving the directory would not remove that step, so the sync is not saving us the back-and-forth you are thinking of. What it actually buys is only that MEPs stay at enhancements/, next to the README that documents the process and where someone browsing the repo expects to find them. The price is the script plus the Makefile wiring and two path filters.

Keeping it on that basis for now, but it is a close call and I will move it if you would rather have the ~120 fewer lines. The thing that would flip me is wanting MEPs to use the rest of the docs tooling, snippets and cross-page links, since that is markedly simpler inside docs_dir.

The comment narrated the change rather than the code. What a later reader
needs is the dependency itself: enhancements/ is outside docs_dir, so the
filters only work because make docs stages it.

Signed-off-by: Carlos Eduardo Arango Gutierrez <eduardoa@nvidia.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

docs(pages): publish the enhancement proposals on the documentation site

2 participants