Skip to content

docs: improve gw help per CLI_RULE.md review - #41

Merged
zawakin merged 1 commit into
mainfrom
feature/improve-help
Jun 29, 2026
Merged

docs: improve gw help per CLI_RULE.md review#41
zawakin merged 1 commit into
mainfrom
feature/improve-help

Conversation

@zawakin

@zawakin zawakin commented Jun 29, 2026

Copy link
Copy Markdown
Contributor

Improves gw's --help/-h/error output against the CLI Help Design Rules, targeting the CLI_REVIEW_V1 gw findings (scored 5.5/10).

Changes

First line (Rule 1) — dropped the builder-jargon type-safe worktree-aware git operations for user value:

Worktree-aware git workflow: branch -> PR -> cleanup, safely.

--help now earns its keystrokes (Rules 3, 5, 8, 9, 11) — added a long_about shown only on --help, while -h stays a compact command list. It carries:

  • a TYPICAL FLOW quick start (gw new → commit/push/PR → gw await)
  • a "home branch" definition on first use
  • commands grouped by situation (Everyday / Recovery / Worktrees)
  • the named audience (developers on a PR-per-branch workflow)

clap auto-appends (see more with '--help') to -h, signalling the divergence (Rule 6).

Actionable errors (Rule 13)gw <badcmd> / gw await (missing arg) now end with a runnable next command instead of clap's bare footer:

Try:
  gw status     # show where you are and the next command to run
  gw --help     # full command reference

--help/--version still exit 0; usage errors exit 2.

Verification

mise run verify passes (fmt, clippy, tests, build). Manually checked -h, --help, gw stauts, gw await, bare gw, --version.

🤖 Generated with Claude Code

Address the CLI_REVIEW_V1 findings for gw:

- Rule 1: drop builder-jargon "type-safe" from the first line; lead with
  user value ("Worktree-aware git workflow: branch -> PR -> cleanup, safely").
- Rule 3/5/8/9/11: add a rich --help (long_about) with a TYPICAL FLOW quick
  start, a "home branch" definition, situational command grouping (Everyday /
  Recovery / Worktrees), and the named audience -- while keeping -h compact.
  clap now signals the divergence with "(see more with '--help')".
- Rule 13: usage errors (bad subcommand, missing arg) now print a "Try:"
  footer pointing at a runnable next command (gw status) plus gw --help.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@zawakin zawakin self-assigned this Jun 29, 2026
@zawakin
zawakin merged commit aa753b6 into main Jun 29, 2026
7 checks passed
@zawakin
zawakin deleted the feature/improve-help branch June 29, 2026 09:44
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