Skip to content

Unify flag metadata into a single validated source of truth#3449

Closed
ccclosed wants to merge 2 commits into
BurntSushi:masterfrom
ccclosed:unified-flag-source
Closed

Unify flag metadata into a single validated source of truth#3449
ccclosed wants to merge 2 commits into
BurntSushi:masterfrom
ccclosed:unified-flag-source

Conversation

@ccclosed

Copy link
Copy Markdown

Promote the FLAGS registry to a documented, validated single source of truth via a read-only RegistryView, and derive every flag-facing artifact from it: Bash, Zsh, Fish and PowerShell completions, the man page, and -h/--help output.

  • Add RegistryView with registry-wide validation (duplicate/missing-field) and shared category/flag ordering.
  • Replace the panicking custom-markup path with a fallible Markup_Renderer that centralizes roff hyphen escaping.
  • Generate the Zsh completion's per-flag content from the registry (new !FLAGS! splice point) while keeping the hand-written scaffold and contextual grouping.
  • Make value completion consistent across all four shells and complete negated names and aliases everywhere.
  • Add a structured Consistency_Checker that reports all divergences; wire its real-registry test as the authoritative CI drift guard, replacing the loose zsh-only ci/test-complete.
  • Formalize the --generate command contract and add integration tests.
  • Implement all 25 design properties as proptest property tests plus example tests.

Spec: .kiro/specs/unified-flag-source

Promote the FLAGS registry to a documented, validated single source of truth via a read-only RegistryView, and derive every flag-facing artifact from it: Bash, Zsh, Fish and PowerShell completions, the man page, and -h/--help output.

- Add RegistryView with registry-wide validation (duplicate/missing-field) and shared category/flag ordering.
- Replace the panicking custom-markup path with a fallible Markup_Renderer that centralizes roff hyphen escaping.
- Generate the Zsh completion's per-flag content from the registry (new !FLAGS! splice point) while keeping the hand-written scaffold and contextual grouping.
- Make value completion consistent across all four shells and complete negated names and aliases everywhere.
- Add a structured Consistency_Checker that reports all divergences; wire its real-registry test as the authoritative CI drift guard, replacing the loose zsh-only ci/test-complete.
- Formalize the --generate command contract and add integration tests.
- Implement all 25 design properties as proptest property tests plus example tests.

Spec: .kiro/specs/unified-flag-source
@ccclosed ccclosed marked this pull request as draft June 26, 2026 10:32
Add /.kiro and /.VSCodeCounter to .gitignore and remove the previously committed .kiro spec directory from version control. The files remain on disk locally.
@ccclosed ccclosed marked this pull request as ready for review June 26, 2026 10:36
@ccclosed ccclosed closed this Jun 26, 2026
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