gz-cli-audit
Use to verify every CLI command has its manpage, headings and index entry.
Files2
View on GitHubSKILL.md.gzkit/skills/gz-cli-audit/SKILL.md
GitHubgz cli audit
Overview
Check that every CLI command's documentation exists and agrees with the parser.
gz cli audit reads the command roster in config/doc-coverage.json and checks:
- each command with a manpage surface has
docs/user/manpages/<slug>.md, whose first line is# gz <command>and whichdocs/user/manpages/index.mdlinks; - every
gzcommand in the README## Quick Startblock parses against the live CLI; - cross-coverage: each command discovered from the parser source has a manpage,
an index entry, a reference in the operator runbook and in the governance
runbook, and a handler docstring, unless the manifest sets that surface to
false; a deprecated verb must instead be absent from both runbooks; a manpage with no matching command is an orphan; - each long flag is named in its manpage, and the manpage's usage block does not bracket a required flag as optional or show a valueless flag taking a value.
It is read-only. It exits 0 with CLI audit passed. and exits 1 when it lists
any issue. In an adopter project with no config/doc-coverage.json it skips
with exit 0; in gzkit's own tree a missing manifest is an issue. gz check runs
it as the CLI audit step.
Workflow
- Run
uv run gz cli audit, or add--jsonfor{valid, issues, cross_coverage}. - On exit 1, fix each named surface: write or retitle the manpage, add its index link, reference the command in the runbook the issue names, add the handler docstring, correct the Quick Start line, or make the usage block match the parser. Remove an orphaned manpage only when its command is gone.
- Re-run until it exits 0, then summarize what changed.
Example
uv run gz cli audit
uv run gz cli audit --json