Merge branch 'main' into ci/168-helm-chart-ci-gate
CI / lint (pull_request) Successful in 1m24s
CI / k8s (pull_request) Successful in 8s
CI / build (pull_request) Successful in 1m1s
CI / unit (pull_request) Successful in 1m7s
CI / frontend (pull_request) Successful in 1m50s
CI / mutation (pull_request) Successful in 3m37s
CI / verify-stack (pull_request) Successful in 6m13s
CI / lint (pull_request) Successful in 1m24s
CI / k8s (pull_request) Successful in 8s
CI / build (pull_request) Successful in 1m1s
CI / unit (pull_request) Successful in 1m7s
CI / frontend (pull_request) Successful in 1m50s
CI / mutation (pull_request) Successful in 3m37s
CI / verify-stack (pull_request) Successful in 6m13s
This commit is contained in:
Executable
+30
@@ -0,0 +1,30 @@
|
||||
#!/usr/bin/env python3
|
||||
"""Fail when a page under docs/ is missing from mkdocs.yml's nav.
|
||||
|
||||
docs/ is the source of truth (CLAUDE.md §12), but only the pages listed in the nav
|
||||
are published — and mkdocs' own `omitted_files: warn` keeps a build green while
|
||||
silently dropping them, which is how every ADR after 0010 and every runbook but
|
||||
ci.md fell off the site.
|
||||
|
||||
ponytail: a substring test, not a YAML parse — a page's path either appears in
|
||||
mkdocs.yml or it doesn't, and that needs no dependency.
|
||||
"""
|
||||
|
||||
import sys
|
||||
from pathlib import Path
|
||||
|
||||
ROOT = Path(__file__).resolve().parents[1]
|
||||
nav = (ROOT / "mkdocs.yml").read_text()
|
||||
|
||||
missing = sorted(
|
||||
str(page.relative_to(ROOT / "docs"))
|
||||
for page in (ROOT / "docs").rglob("*.md")
|
||||
if str(page.relative_to(ROOT / "docs")) not in nav
|
||||
)
|
||||
|
||||
if missing:
|
||||
print(f"{len(missing)} page(s) under docs/ are not in mkdocs.yml's nav:")
|
||||
print("\n".join(f" {m}" for m in missing))
|
||||
sys.exit(1)
|
||||
|
||||
print("docs nav complete: every page under docs/ is published")
|
||||
Reference in New Issue
Block a user