Normalize CLI help semantics for verbose/cool-down/days/spec wording and logs cache-eviction flag#32385
Merged
Merged
Conversation
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Fix CLI consistency issues in command help text
Normalize CLI help semantics for verbose/cool-down/days/spec wording and logs cache-eviction flag
May 15, 2026
Contributor
There was a problem hiding this comment.
Pull request overview
This PR normalizes CLI help/flag semantics across several commands, mainly aligning shared wording and replacing the ambiguous logs cache-eviction --after flag with --cache-before.
Changes:
- Centralized
--cool-downusage text forupdateanddeploy. - Updated command help/tests for
outcomes,forecast,add-wizard, and logs cache eviction. - Added
logs --cache-beforewith hidden deprecated--afteralias handling.
Show a summary per file
| File | Description |
|---|---|
| pkg/cli/update_cooldown.go | Adds shared cooldown flag usage constant. |
| pkg/cli/update_command.go | Uses shared cooldown usage text. |
| pkg/cli/update_command_test.go | Tests update cooldown flag usage. |
| pkg/cli/outcomes_command.go | Removes local verbose flag. |
| pkg/cli/outcomes_command_test.go | Tests global verbose inheritance. |
| pkg/cli/logs_command.go | Adds --cache-before, keeps hidden --after alias, updates examples. |
| pkg/cli/logs_command_test.go | Updates logs flag/help assertions. |
| pkg/cli/forecast_command.go | Updates --days help and shell completion. |
| pkg/cli/forecast_test.go | Tests --days help text. |
| pkg/cli/deploy_command.go | Uses shared cooldown usage text. |
| pkg/cli/deploy_command_test.go | Tests deploy cooldown flag usage. |
| pkg/cli/add_wizard_command.go | Aligns workflow spec wording with add command. |
| pkg/cli/add_wizard_command_test.go | Tests add-wizard spec wording. |
Copilot's findings
Tip
Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- Files reviewed: 13/13 changed files
- Comments generated: 2
| Format: format, | ||
| ArtifactSets: artifacts, | ||
| After: after, | ||
| After: cacheBefore, |
Comment on lines
+224
to
+229
| cacheBefore, _ := cmd.Flags().GetString("cache-before") | ||
| if !cmd.Flags().Changed("cache-before") { | ||
| if cmd.Flags().Changed("after") { | ||
| cacheBefore, _ = cmd.Flags().GetString("after") | ||
| } | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Bug Fix
The CLI consistency checker flagged five help-surface inconsistencies across 33 commands: verbose flag shadowing, divergent
--cool-downwording, incomplete--daysconstraints,add/add-wizardspec wording drift, and ambiguouslogs --afternaming.What was the bug?
Help text and flag semantics diverged across commands for equivalent behavior, with one misleading flag name (
--after) that implied run filtering while actually performing cache eviction.How did you fix it?
Verbose flag consistency (
outcomes)--verbose/-vdefinition fromoutcomesso it inherits root/global verbose behavior and wording.Unified
--cool-downhelp text (deploy,update)forecast --daysconstraint surfaced in flag definition--dayshelp text to explicitly list allowed values:7, 30.--dayswith7and30.Aligned workflow spec wording (
add,add-wizard)add-wizard“Workflow specifications” bullets to matchaddfor three-part/four-part path semantics.Disambiguated logs cache eviction flag
--cache-beforeas the primary flag for cache eviction.--after.--cache-beforeis set, it wins; otherwise explicit--afteris used.--cache-before.Example
Testing
outcomesglobal verbose inheritance--cool-downusage textforecast --daysusage wordingadd-wizardspec wording paritylogs--cache-before+ hidden alias behavior