docs(fern): main + latest GA alias, rename v0.2 → v0.2.1, fix CI fork-secret access#1241
docs(fern): main + latest GA alias, rename v0.2 → v0.2.1, fix CI fork-secret access#1241
Conversation
…lias, rename v0.2 → v0.2.1 Reshape the Fern versions tree so "latest" is a GA alias rather than a real folder. New layout: - versions/main/ — bleeding-edge tree (was versions/latest/) - versions/v0.2.1/ — frozen GA snapshot (was versions/v0.2/, version was wrong) - versions/latest.yml — GA alias mirroring v0.2.1.yml; on release, copy the new GA's yaml content here - versions/main.yml + versions/v0.2.1.yml — nav trees with paths updated Body MDX cross-links updated: /latest/ → /main/ inside main/, and /latest/ + /v0.2/ → /v0.2.1/ inside v0.2.1/. _nav_order.yml retargets main/. docs.yml versions list is now Latest (stable) + Main (beta) + 0.2.1 (stable); the v0.2 redirect updates to v0.2.1. Also switch fern-docs-ci.yml from `pull_request` to `push: branches: [pull-request/[0-9]+]`, matching build-docs.yml. This routes fork PRs through the FW-CI mirror bot so DOCS_FERN_TOKEN is available in CI for `fern check`. SKILL.md (nemo-gym-docs) rewritten: edits default to main/, back-ports to GA snapshots are explicit, release ritual snapshots main/ → v<new>/ and copies that yaml content into latest.yml. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com> Signed-off-by: Lawrence Lane <llane@nvidia.com>
Companion to the previous commit. The previous commit captured the git mv renames; this one captures the content edits that followed: - main.yml — paths flipped from ./latest/pages/... to ./main/pages/... - v0.2.1.yml — paths flipped from ./v0.2/pages/... to ./v0.2.1/pages/... - latest.yml — new GA alias file (mirrors v0.2.1.yml; has a header comment describing the alias contract) - _nav_order.yml — paths retargeted to ./versions/main/pages/... - docs.yml — versions list bumped to Latest/Main/0.2.1; v0.2 redirect → v0.2.1 - main/pages/**/*.mdx — body link prefixes /latest/ → /main/ - v0.2.1/pages/**/*.mdx — body link prefixes /latest/ and /v0.2/ → /v0.2.1/ - .claude/skills/nemo-gym-docs/SKILL.md — flow rewrite for the new layout - .github/workflows/fern-docs-ci.yml — switch to push:pull-request/[0-9]+ Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com> Signed-off-by: Lawrence Lane <llane@nvidia.com>
|
also addresses #723 |
…in-versioning Signed-off-by: Lawrence Lane <llane@nvidia.com> # Conflicts: # fern/versions/main/pages/environment-tutorials/designing-customer-evaluation.mdx
There was a problem hiding this comment.
- Missing redirect for /v0.2/ — The existing docs.yml updates the v0.2/:path*/index.html redirect to v0.2.1/, but there's no general /v0.2/:path* → /v0.2.1/:path* redirect. E.g anyone with bookmarks to /v0.2/get-started/quickstart (not .html) would get a 404. I'd add:
- source: "/v0.2/:path*"
destination: "/v0.2.1/:path*"
- The latest.yml --> v0.2.1/ alias pattern is clean. Could we do the same for main? i.e. create main.yml pointing at the existing ./latest/pages/... folder, skip the rename, and significantly reduce the dif making it easier to review. The folder name being latest/ vs main/ is cosmetic — the slug comes from docs.yml, not the folder — and we can always rename later in a standalone PR if we really want folder/slug parity.
That would also let us split this into two smaller, independently reviewable PRs:
- v0.2 → v0.2.1 rename + latest.yml alias + CI fix
- (optional, later) rename latest/ folder to main/ if we decide the cosmetics matter
….yml Revert the cosmetic latest/ → main/ folder rename (and the body link rewrites that came with it) per Chris's review. The folder name doesn't affect public URLs — slugs come from docs.yml — so keeping the folder named latest/ shrinks the diff dramatically without changing behavior. End state in this PR (vs origin/main): - versions/main.yml: new nav for the bleeding-edge train, mounts ./latest/pages (slug: main, beta) - versions/latest.yml: rewritten as a GA alias mirroring v0.2.1.yml, mounts ./v0.2.1/pages (slug: latest, stable) - versions/v0.2/ → versions/v0.2.1/ (folder + yaml rename, paths fixed) - docs.yml: versions list adds Main; v0.2 redirect updated to v0.2.1; new /v0.2/:path* → /v0.2.1/:path* redirect catches non-.html bookmarks - .github/workflows/fern-docs-ci.yml: switch to push:pull-request/[0-9]+ so DOCS_FERN_TOKEN is available for fork PRs - SKILL.md: documents the new model and release ritual The folder name latest/ is now historical (slug: main); a future PR can do the cosmetic rename in isolation if desired. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com> Signed-off-by: Lawrence Lane <llane@nvidia.com>
|
Thanks for the review @cwing-nvidia! Addressed both: 1. Missing - source: "/v0.2/:path*"
destination: "/v0.2.1/:path*"Catches any non- 2. Skip the latest/ → main/ folder rename — done. The folder stays named End-state diff vs main is now 78 files (160/-77) — almost all of which are zero-change renames from Force-push was blocked by branch rules so the prior 3 commits + merge are still in the history, with one new commit on top that walks the cosmetic rename back. The cumulative PR diff is what reviewers see, and that's now the small one. |
There was a problem hiding this comment.
is it possible to define the version once as a variable so it can be changed just once in each path?
…asing - Replace fern/versions/latest.yml with a symlink to v0.2.1.yml so the GA alias has one source of truth; release ritual becomes one ln -sfn. - Generalize SKILL.md phrasing to drop hard-coded version references and the legacy Sphinx/migration framing; clarify that frontmatter position is optional. - Delete the orphaned fern/versions/_nav_order.yml — its consumer (add_frontmatter.py) is no longer in the repo and Fern doesn't read it. Signed-off-by: Lawrence Lane <llane@nvidia.com>
… site Adds the bundled Fern CI suite from the convert-to-fern toolkit and the `experimental.basepath-aware: true` flag required for subpath-hosted sites (docs.nvidia.com/nemo/automodel). - fern-docs-ci.yml — `fern check` on PRs. Trigger uses the FW-CI mirror bot pattern (`push: branches: pull-request/[0-9]+`) — same as build-docs.yml — so DOCS_FERN_TOKEN is available even for fork PRs. This is the fix landed in NVIDIA-NeMo/Gym#1241. - fern-docs-preview-build.yml + fern-docs-preview-comment.yml — two-workflow split: build collects PR sources without secrets (safe for forks), comment workflow is triggered via workflow_run with the trusted base context, builds the preview, and posts a herb-emoji PR comment. - publish-fern-docs.yml — publishes to docs.nvidia.com/nemo/automodel on push to main with fern/** changes or via workflow_dispatch. Required org secret: DOCS_FERN_TOKEN (already present for build-docs.yml). Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
… site Adds the bundled Fern CI suite from the convert-to-fern toolkit and the `experimental.basepath-aware: true` flag required for subpath-hosted sites (docs.nvidia.com/nemo/automodel). - fern-docs-ci.yml — `fern check` on PRs. Trigger uses the FW-CI mirror bot pattern (`push: branches: pull-request/[0-9]+`) — same as build-docs.yml — so DOCS_FERN_TOKEN is available even for fork PRs. This is the fix landed in NVIDIA-NeMo/Gym#1241. - fern-docs-preview-build.yml + fern-docs-preview-comment.yml — two-workflow split: build collects PR sources without secrets (safe for forks), comment workflow is triggered via workflow_run with the trusted base context, builds the preview, and posts a herb-emoji PR comment. - publish-fern-docs.yml — publishes to docs.nvidia.com/nemo/automodel on push to main with fern/** changes or via workflow_dispatch. Required org secret: DOCS_FERN_TOKEN (already present for build-docs.yml). Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com> Signed-off-by: Lawrence Lane <llane@nvidia.com>
…liases Per the NeMo Gym pattern (NVIDIA-NeMo/Gym#1241): the bleeding-edge tree that gets updated on every PR lives at versions/nightly/pages/, and GA snapshots are cut from it at release time. The previous setup labeled the same tree as "v0.4" — which was misleading because the content is post-0.4.0-tag main, not the v0.4.0 release content. - Renamed versions/v0.4/ → versions/nightly/ (all 130+ pages) - Renamed versions/v0.4.yml → versions/nightly.yml (paths point at ./nightly/pages/ instead of ./v0.4/pages/) - Recreated versions/latest.yml and versions/v0.4.yml as fresh copies of nightly.yml, both pointing at ./nightly/pages/. They serve as aliases until a real frozen v0.4.0 snapshot is migrated from the v0.4.0 git tag (out of scope for this PR). - Reordered docs.yml versions: nightly (beta) listed first as the canonical/editable tree; Latest (stable) and "0.4.0 · 26.04" (stable) are now aliases. - Updated fern/README.md and skills/fern-docs/SKILL.md to call nightly canonical and document the alias relationship + the cut-a-new-train cookbook (cp -r nightly v0.5; repoint latest). Validation: all 5 primary + both secondary checks pass; URLMap still resolves all 128 pages. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com> Signed-off-by: Lawrence Lane <llane@nvidia.com>
Orientation for the Fern docs site: layout, local dev via the (in-flight) Make targets and the underlying npm scripts, authoring conventions (frontmatter, components, internal links), versioning, CI workflows, and a troubleshooting table covering the dashboard-provisioning HTTP 403 and other common stumbles. Signed-off-by: Lawrence Lane <llane@nvidia.com>
Summary
Release ritual (now codified in SKILL.md)
On cutting v0.3.0:
Test plan
🤖 Generated with Claude Code