Skip to content

docs(mkdocs): flatten DLP entries in CLI Reference sidebar#225

Merged
cdot65 merged 1 commit into
mainfrom
cdot65/docs/flatten-dlp-cli-nav
May 28, 2026
Merged

docs(mkdocs): flatten DLP entries in CLI Reference sidebar#225
cdot65 merged 1 commit into
mainfrom
cdot65/docs/flatten-dlp-cli-nav

Conversation

@cdot65

@cdot65 cdot65 commented May 28, 2026

Copy link
Copy Markdown
Owner

Summary

  • The CLI Reference sidebar collapsed runtime dlp dictionaries, runtime dlp filtering-profiles, runtime dlp patterns, and runtime dlp profiles under a separate "Dlp" group because mkdocs literate-nav auto-generated the nav from the docs/cli/runtime/dlp/ subdirectory. Fix: generator now writes docs/cli/SUMMARY.md listing every page flat under its top-level group; literate-nav consumes it instead of inferring from directory layout.
  • New pure renderSummary(pages) in scripts/cli-docs/render.ts (5 new unit tests).
  • gen-cli-docs.ts writes docs/cli/SUMMARY.md alongside index.md.
  • No URLs, no command structure, no file moves changed. Pages keep their existing paths.

Verified by inspecting site/cli/runtime/dlp/dictionaries/index.html: pre-fix had >Dlp< label spanning 4 children; post-fix has no nested Dlp label and the 4 DLP entries appear as flat siblings under Runtime alongside airs runtime api-keys, airs runtime dlp-gen, airs runtime dlp-profiles, etc.

Side effect: the build no longer emits warnings about cli/examples/README.md / cli/examples/REDACTION.md being referenced from nav — they're not in SUMMARY.md so literate-nav stops trying to include them.

Per CLAUDE.md § Releases this is queued as a .changeset/*.md patch; no version bump in this PR.

Test plan

  • renderSummary unit tests: groups by top-level command, DLP entries flat under Runtime, no nested "Dlp" label, pre-existing flat pages (dlp-gen, dlp-profiles) not duplicated, entries sorted alphabetically, all 3 top-level groups present
  • pnpm lint clean
  • pnpm tsc --noEmit clean
  • pnpm test 704/704
  • pnpm docs:check clean
  • pnpm docs:build clean (warnings about cli/examples nav references also gone as a happy side-effect)
  • CI green
  • After merge, verify https://cdot65.github.io/prisma-airs-cli/cli/ sidebar shows DLP entries flat

Add renderSummary() that emits docs/cli/SUMMARY.md mapping every
generated page flat under its top-level group (runtime/redteam/
model-security). literate-nav consumes the SUMMARY.md, so the four
runtime/dlp/* pages appear as siblings of runtime/* instead of under
a nested "Dlp" group. No URLs change; only sidebar render order.
@cdot65 cdot65 merged commit c7804de into main May 28, 2026
5 checks passed
@cdot65 cdot65 deleted the cdot65/docs/flatten-dlp-cli-nav branch May 28, 2026 09:48
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.

1 participant