Skip to content

fix: address 14 CLI consistency issues (branding, descriptions, docs)#47592

Open
pelikhan with Copilot wants to merge 6 commits into
mainfrom
copilot/cli-consistency-fix-documentation
Open

fix: address 14 CLI consistency issues (branding, descriptions, docs)#47592
pelikhan with Copilot wants to merge 6 commits into
mainfrom
copilot/cli-consistency-fix-documentation

Conversation

Copilot AI commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

Fixes 14 of 15 CLI consistency issues found by static source analysis across pkg/cli/*.go and docs/src/content/docs/setup/cli.md. Issues ranged from users unable to discover available flags to stale branding and self-referential deprecation messages.

Source code

  • cmd/gh-aw/main.go: Remove stale "from GitHub Next" branding from root command Short/Long; fix circular -F deprecation message ("use --raw-field instead""use the long form --raw-field instead")
  • pkg/cli/audit_diff_command.go: Surface deprecation in Short"[Deprecated] Compare workflow runs (use: gh aw audit <base> <compare...>)"
  • pkg/cli/validate_command.go: Replace inline cmd.Flags().BoolP("json", "j", ...) with addJSONFlag(cmd) helper (single source of truth)
  • pkg/cli/mcp_server_command.go: Align Short to match Long's relative-clause phrasing
  • pkg/cli/lint_command.go: "workflows""workflow files" in Short
  • pkg/cli/env_command.go: "GitHub variables""GitHub Actions variables" in Short; standardize --repo descriptions to [HOST/]owner/repo format
  • pkg/cli/doctor_command.go: Standardize --repo description to canonical form (add "Defaults to current repository")

Docs (docs/src/content/docs/setup/cli.md)

  • pr transfer (High): Add missing **Options:** \--repo/-r`` — users had no way to discover this flag
  • logs: Add --evals to Options list (implemented but absent)
  • secrets bootstrap: --engine--engine/-e to expose implemented short form
  • fix: Add rationale note explaining why --disable-codemod uses value-taking flag semantics instead of the --no-X pattern used elsewhere
  • compile: Add prose callouts for --syft (SBOM), --grype (vulnerability scanner), --runner-guard (taint analysis) — flags were listed in Options but undescribed

Not applied

The deploy --pr alias finding is inapplicable: deploy unconditionally creates a PR and has no --create-pull-request boolean flag to alias.


$

Generated by 👨‍🍳 PR Sous Chef · gpt54 11.6 AIC · ⌖ 7.58 AIC · ⊞ 7K ·
Comment /souschef to run again


Run: https://github.com/github/gh-aw/actions/runs/30035273314

Generated by 👨‍🍳 PR Sous Chef · gpt54 · 18 AIC · ⌖ 10.1 AIC · ⊞ 7K ·
Comment /souschef to run again


Run: https://github.com/github/gh-aw/actions/runs/30042541462

Generated by 👨‍🍳 PR Sous Chef · gpt54 · 12.1 AIC · ⌖ 9.05 AIC · ⊞ 7K ·
Comment /souschef to run again


Generated by 👨‍🍳 PR Sous Chef · gpt54 · 10.4 AIC · ⌖ 6.78 AIC · ⊞ 7K ·
Comment /souschef to run again


Generated by 👨‍🍳 PR Sous Chef · gpt54 · 9.66 AIC · ⌖ 8.72 AIC · ⊞ 7K ·
Comment /souschef to run again

Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix options section missing for pr transfer command in CLI docs fix: address 14 CLI consistency issues (branding, descriptions, docs) Jul 23, 2026
Copilot AI requested a review from pelikhan July 23, 2026 14:46
@pelikhan
pelikhan marked this pull request as ready for review July 23, 2026 14:49
Copilot AI review requested due to automatic review settings July 23, 2026 14:49

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Standardizes CLI help text, branding, flag descriptions, and documentation.

Changes:

  • Aligns command descriptions and shared flag helpers.
  • Corrects deprecated flag guidance and stale branding.
  • Expands documentation for existing CLI options.
Show a summary per file
File Description
cmd/gh-aw/main.go Updates branding and deprecation guidance.
pkg/cli/audit_diff_command.go Marks the legacy command deprecated.
pkg/cli/validate_command.go Uses the shared JSON flag helper.
pkg/cli/mcp_server_command.go Aligns MCP server descriptions.
pkg/cli/lint_command.go Clarifies lint scope.
pkg/cli/env_command.go Updates branding and repository help.
pkg/cli/doctor_command.go Revises repository flag help.
docs/src/content/docs/setup/cli.md Documents additional flags and scanners.

Review details

Tip

Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comments suppressed due to low confidence (1)

pkg/cli/env_command.go:201

  • The new help text advertises the three-part HOST/owner/repo form, but resolveDefaultsTarget passes this value to repoutil.SplitRepoSlug, which rejects anything other than exactly owner/repo (pkg/repoutil/repoutil.go:17-20). Users following this help receive an invalid repository error. Keep the documented format to what this command currently accepts, or add host parsing and host selection before advertising it.
	cmd.Flags().StringVarP(&repo, "repo", "r", "", "Target repository ([HOST/]owner/repo format). Defaults to current repository")
  • Files reviewed: 8/8 changed files
  • Comments generated: 4
  • Review effort level: Medium

Comment thread cmd/gh-aw/main.go
runCmd.Flags().Bool("auto-merge-prs", false, "Auto-merge any pull requests created during the workflow execution")
runCmd.Flags().StringArrayP("raw-field", "F", []string{}, "Pass a workflow dispatch input in key=value format (can be specified multiple times)")
_ = runCmd.Flags().MarkShorthandDeprecated("raw-field", "use --raw-field instead")
_ = runCmd.Flags().MarkShorthandDeprecated("raw-field", "use the long form --raw-field instead")

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed in the latest commit — the test assertion now matches the new deprecation text "use the long form --raw-field instead".

Comment thread pkg/cli/env_command.go Outdated

cmd.Flags().StringVar(&scope, "scope", "", "Variable scope (repo|org|ent). Defaults to repo")
cmd.Flags().StringVarP(&repo, "repo", "r", "", "Target repository in owner/repo format. When omitted, defaults to current repository")
cmd.Flags().StringVarP(&repo, "repo", "r", "", "Target repository ([HOST/]owner/repo format). Defaults to current repository")

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed in the latest commit — both --repo descriptions in env_command.go (lines 162 and 201) now document owner/repo format, matching what resolveDefaultsTarget/SplitRepoSlug actually accepts.

Comment thread pkg/cli/doctor_command.go Outdated
}

cmd.Flags().StringP("repo", "r", "", "Target repository in [HOST/]owner/repo format")
cmd.Flags().StringP("repo", "r", "", "Target repository ([HOST/]owner/repo format). Defaults to current repository")

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed in the latest commit — the --repo description in doctor_command.go now reads "Target repository (owner/repo format)". The misleading "Defaults to current repository" claim is removed since omitting --repo triggers auth-only diagnostics, not repository checks.

Comment on lines +349 to +350
- **`--syft`:** Generates a Software Bill of Materials (SBOM) for container images referenced in compiled workflows using the Syft scanner.
- **`--grype`:** Scans container images referenced in compiled workflows for known vulnerabilities using the Grype vulnerability scanner.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed in the latest commit — --grype and --syft are now included in the canonical compile Options list, in alphabetical order (--grype between --grant and --json/-j; --syft between --strict and --trial).

@github-actions

github-actions Bot commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

🧠 Matt Pocock Skills Reviewer has completed the skills-based review. ✅

@github-actions

github-actions Bot commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

Test Quality Sentinel completed test quality analysis.

No test files were added or modified in this PR. This PR (#47592) contains only documentation updates and CLI consistency fixes (branding, descriptions, docs). Test Quality Sentinel analysis skipped.

@github-actions

github-actions Bot commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

PR Code Quality Reviewer completed the code quality review.

@github-actions

github-actions Bot commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

Design Decision Gate 🏗️ completed the design decision gate check.

No ADR enforcement needed: PR #47592 does not have the 'implementation' label and has only 8 new lines of code in business logic directories (threshold: 100).

@gh-aw-bot

Copy link
Copy Markdown
Collaborator

@copilot please run the pr-finisher skill, address unresolved review comments, and rerun checks once the branch is up to date.

Unresolved review threads (newest first):

Failed checks:

Generated by 👨‍🍳 PR Sous Chef · gpt54 11.6 AIC · ⌖ 7.58 AIC · ⊞ 7K ·
Comment /souschef to run again

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review Summary

This PR makes solid consistency improvements across CLI descriptions and docs. However, there are 3 blocking issues that must be addressed before merge (all already called out in inline comments):

  1. Test failure (cmd/gh-aw/main_help_text_test.go:27) — The test still asserts "use --raw-field instead" but the changed code now emits "use the long form --raw-field instead". The test will fail deterministically. Update the test to match.

  2. Misleading --repo description in env_command.go — The new help text advertises [HOST/]owner/repo, but resolveDefaultsTarget passes this value to repoutil.SplitRepoSlug, which only accepts owner/repo. Advertising a format the code cannot handle misleads users.

  3. Incorrect doctor --repo default description"Defaults to current repository" implies omitting --repo runs full repo diagnostics, but the repo == "" branch only runs auth-only diagnostics. The description must match actual behavior.

The docs-only changes (--evals, --engine/-e, --syft/--grype/--runner-guard callouts, --repo/-r for pr transfer, --disable-codemod rationale) are all clean and correct.

🧵 Reviewed using Impeccable skills by Impeccable Skills Reviewer · sonnet46 21.3 AIC · ⌖ 4.57 AIC · ⊞ 5K

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Skills-Based Review 🧠

Applied /diagnosing-bugs and /grill-with-docs — requesting changes on test correctness and documentation consistency issues.

📋 Key Themes & Highlights

Key Issues (see existing inline comments)

The four existing inline comments from @Copilot already identify the most impactful problems:

  1. Test breakage (cmd/gh-aw/main.go:814) — The deprecation message change breaks main_help_text_test.go:27; the assertion must be updated to match.
  2. Misleading flag doc vs. actual parsing (pkg/cli/env_command.go:162) — Help text advertises HOST/owner/repo but resolveDefaultsTargetrepoutil.SplitRepoSlug only accepts owner/repo; either fix the parser or revert the doc.
  3. False default claim (pkg/cli/doctor_command.go:62) — "Defaults to current repository" is inaccurate: the empty-repo branch runs auth-only diagnostics, not repo diagnostics.
  4. Docs options list incomplete (docs/src/content/docs/setup/cli.md:350) — --syft and --grype are described in prose but absent from the canonical Options list above.

Positive Highlights

  • ✅ Clean use of addJSONFlag(cmd) helper in validate_command.go — good single-source-of-truth fix
  • [Deprecated] prefix in audit_diff_command.go Short is discoverable and consistent
  • ✅ "GitHub Actions variables" rename is accurate and aligns with platform terminology
  • --disable-codemod rationale note in docs is genuinely helpful for users wondering why the pattern differs

🧠 Reviewed using Matt Pocock's skills by Matt Pocock Skills Reviewer · sonnet46 18.3 AIC · ⌖ 4.61 AIC · ⊞ 6.7K
Comment /matt to run again

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

4 blocking issues require fixes before merge.

📋 Blocking themes

Test suite breakage

The deprecation message change in main.go breaks an existing unit test that asserts the exact old string. CI will fail deterministically.

Misleading flag documentation

Two flag descriptions claim behaviour the implementation does not deliver:

  • doctor --repo: says "Defaults to current repository" but omitting --repo skips repo diagnostics entirely (auth-only path).
  • env --repo: advertises [HOST/]owner/repo but the underlying resolver rejects that form.

Incomplete docs

The compile Options list still omits --syft and --grype even though the new prose now describes those flags.

All other changes (branding, addJSONFlag refactor, short description wording) look correct.

🔎 Code quality review by PR Code Quality Reviewer · sonnet46 32.5 AIC · ⌖ 4.52 AIC · ⊞ 5.7K
Comment /review to run again

Copilot AI and others added 2 commits July 23, 2026 15:07
Co-authored-by: gh-aw-bot <259018956+gh-aw-bot@users.noreply.github.com>
…ptions list)

Co-authored-by: gh-aw-bot <259018956+gh-aw-bot@users.noreply.github.com>
Copilot AI requested a review from gh-aw-bot July 23, 2026 15:17
@github-actions

Copy link
Copy Markdown
Contributor

🤖 PR Triage

Field Value
Category bug
Risk 🟡 Medium
Priority Score 65/100
Recommended Action fast_track

Score breakdown: Impact 28 + Urgency 20 + Quality 17

Batch: batch-lint-cli with #47601

Rationale: Not draft, CI is passing (canary-go, Windows), fixes 14 real CLI UX gaps (flag discoverability, branding, docs). Multiple bot review rounds with changes requested. Good candidate for expedited human review after addressing bot feedback.

Generated by 🔧 PR Triage Agent · sonnet46 · 38.1 AIC · ⌖ 6.75 AIC · ⊞ 5.7K ·

@gh-aw-bot

Copy link
Copy Markdown
Collaborator

@copilot please run the pr-finisher skill, address the unresolved blocking review feedback, and rerun checks once the branch is up to date.

Unresolved review feedback (newest first):

Run: https://github.com/github/gh-aw/actions/runs/30035273314

Generated by 👨‍🍳 PR Sous Chef · gpt54 · 18 AIC · ⌖ 10.1 AIC · ⊞ 7K ·
Comment /souschef to run again

Copilot AI commented Jul 23, 2026

Copy link
Copy Markdown
Contributor Author

@copilot please run the pr-finisher skill, address the unresolved blocking review feedback, and rerun checks once the branch is up to date.

Unresolved review feedback (newest first):...

All four issues raised in both CHANGES_REQUESTED reviews are already fixed in commit 08aad5b:

  1. main_help_text_test.go:27 assertion updated to "use the long form --raw-field instead"TestRunCommandHelpTextConsistency passes locally.
  2. env_command.go (lines 162, 201) --repo description changed from [HOST/]owner/repo to owner/repo format to match what SplitRepoSlug accepts.
  3. doctor_command.go --repo description simplified to owner/repo format with the false "Defaults to current repository" claim removed.
  4. --grype and --syft added to the compile Options list in cli.md in alphabetical order.

Full local test suite passes. The two CHANGES_REQUESTED reviews from github-actions[bot] were against commit a66925a and will be superseded once CI is re-triggered against the current HEAD. CI needs a human re-trigger (close/reopen, workflow_dispatch, or a new push).

@gh-aw-bot

Copy link
Copy Markdown
Collaborator

@copilot please run the pr-finisher skill, verify the unresolved github-actions requested review feedback is fully addressed on the current head, and summarize whether a maintainer only needs to dismiss stale reviews or rerun checks.

Unresolved review feedback (newest first):

  • github-actions requested changes in the existing review history; please confirm each requested item is already fixed or call out any remaining gaps.

Generated by 👨‍🍳 PR Sous Chef · gpt54 · 10.4 AIC · ⌖ 6.78 AIC · ⊞ 7K ·
Comment /souschef to run again

Copilot AI commented Jul 23, 2026

Copy link
Copy Markdown
Contributor Author

@copilot please run the pr-finisher skill, verify the unresolved github-actions requested review feedback is fully addressed on the current head, and summarize whether a maintainer only needs to d...

All four items from the github-actions[bot] CHANGES_REQUESTED reviews are fully addressed on current HEAD (08aad5b). Here's the status:


  • Reviews — All four copilot-pull-request-reviewer threads have been replied to and fixed in 08aad5b:

    1. main_help_text_test.go:27 assertion updated to "use the long form --raw-field instead" — passes locally.
    2. env_command.go --repo descriptions (lines 162, 201) changed from [HOST/]owner/repo to owner/repo format.
    3. doctor_command.go --repo description simplified to "Target repository (owner/repo format)" — false "Defaults to current repository" claim removed.
    4. --grype and --syft added to compile Options list in cli.md in alphabetical order.
    • Threads 2 and 3 are marked is_outdated: true by GitHub (the diff positions moved), but their code fixes are confirmed in the current file state.
  • Checks (local)make test-unit-all passes with zero failures. The previously failing TestRunCommandHelpTextConsistency now passes.

  • Checks (CI) — Stale after agent push; needs human re-trigger. The two CHANGES_REQUESTED reviews were submitted against commit a66925a; the CGO run on current HEAD 08aad5b was cancelled (not failed). The lint-go failure visible in run 30017221989 covers pre-existing non-compliance across many pkg/cli/*.go files unrelated to this PR's changes.

  • Mergeable — Branch is clean, no uncommitted changes, no conflicts.

What a maintainer needs to do:

  1. Re-trigger CI (close/reopen the PR, workflow_dispatch, or push a trivial commit) — the agent's pushes do not trigger workflows.
  2. Dismiss the two stale CHANGES_REQUESTED reviews from github-actions[bot] (submitted against a66925a) since all requested items are addressed in 08aad5b.

@gh-aw-bot

Copy link
Copy Markdown
Collaborator

@copilot please run the pr-finisher skill, ensure this branch is up to date, and address any remaining unresolved review feedback before summarizing merge readiness.

Generated by 👨‍🍳 PR Sous Chef · gpt54 · 9.66 AIC · ⌖ 8.72 AIC · ⊞ 7K ·
Comment /souschef to run again

…cy-fix-documentation

# Conflicts:
#	.github/workflows/daily-team-evolution-insights.lock.yml

Co-authored-by: gh-aw-bot <259018956+gh-aw-bot@users.noreply.github.com>

Copilot AI commented Jul 23, 2026

Copy link
Copy Markdown
Contributor Author

@copilot please run the pr-finisher skill, ensure this branch is up to date, and address any remaining unresolved review feedback before summarizing merge readiness.

...

Branch is now up to date with main (merged c834b37 — AWF v0.27.39, MCP gateway v0.4.4; the only conflict was in an upstream-managed .lock.yml and was resolved by taking the main version).

All four unresolved review threads remain addressed on the current HEAD — fixes were in 08aad5b and are confirmed present after the merge. make test-unit-all passes (including TestRunCommandHelpTextConsistency).

Merge-readiness summary:

  • Reviews — All four copilot-pull-request-reviewer threads replied to and fixed. Two are marked is_outdated by GitHub because the diff positions moved; the code fixes are confirmed present in the current files.
  • Checks (local) — All unit tests pass post-merge.
  • Checks (CI) — Stale; needs human re-trigger (close/reopen, workflow_dispatch, or a maintainer push).
  • Mergeable — Branch is clean and up to date with main.

Still needed from a maintainer: re-trigger CI and dismiss the two stale CHANGES_REQUESTED reviews from github-actions[bot] (submitted against a66925a).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[cli-consistency] CLI Consistency Issues - 2026-07-23

4 participants