Commit 51a44ec
committed
fix(scripts): assert ADR numbers name one decision + repair a broken ADR link (#5992)
`check-adr-anchors` now audits the premise every anchor rests on: an ADR
number identifies exactly ONE decision. Three numbers under `docs/adr/`
were each claimed by two unrelated records (0010 / 0019 / 0057); they are
grandfathered on an explicit, shrink-only allowlist in the script, so a
FOURTH collision fails the ESLint job. Successive versions of one decision
(`0006-project-environment-split{,.v2,.v4}.md`) are distinguished
structurally — same stem plus `.vN` — not by naming 0006.
`--self-test` provokes the red paths on synthetic directories and asserts,
against the live tree, that dropping the allowlist surfaces exactly the
three known collisions.
Also fixes the broken relative link in
`0057-erp-authorization-core-business-units-and-scope-depth.md`, which
pointed at `./0010-metadata-protection.md` (the file is
`0010-metadata-protection-model.md`).
Route C of the maintainer ruling on #5992. Route B (slug-qualified
references) and route A (renumbering) are deliberately not implemented.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01F8q5J1MQyocgtNspb15fSn1 parent a36db28 commit 51a44ec
4 files changed
Lines changed: 402 additions & 11 deletions
File tree
- .github/workflows
- docs/adr
- scripts
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
182 | 182 | | |
183 | 183 | | |
184 | 184 | | |
185 | | - | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
186 | 194 | | |
187 | 195 | | |
188 | 196 | | |
| |||
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
43 | | - | |
| 43 | + | |
44 | 44 | | |
45 | 45 | | |
46 | 46 | | |
| |||
0 commit comments