Skip to content

List subgroup commands when --help is requested and make the unknown-command suggestion runnable - #19450

Open
ThePrimeagen wants to merge 2 commits into
omacom:quattrofrom
ThePrimeagen:fix/c25ceea5-b76b-4aad-8158-83e7c228dbd8
Open

ThePrimeagen wants to merge 2 commits into
omacom:quattrofrom
ThePrimeagen:fix/c25ceea5-b76b-4aad-8158-83e7c228dbd8

Conversation

@ThePrimeagen

Copy link
Copy Markdown
Contributor

Typing omarchy install service --help in a terminal should list the service installers, but bin/omarchy refuses it as an unknown command and suggests omarchy install ?, which fails the same way when run as printed.

Screenshots

Before After
before after

Reproduce

  1. Press Super+Enter to open a terminal.
  2. Type omarchy install service --help and press Enter.
  3. It prints Unknown Omarchy command: omarchy install service --help and Did you mean: omarchy install ? with exit 127, instead of listing the omarchy install service commands.

More cases

Suggestion run verbatim loops

Before After
before after

Another subgroup --help

Before After
before after

Unknown subcommand under a valid group

Before After
before after

Related

In dispatch_or_help, strip trailing --help, -h or ? tokens before
calling show_prefix_help, so 'omarchy install service --help',
'omarchy install gaming --help' and the printed 'omarchy install ?'
match the 'omarchy install service ', 'omarchy install gaming ' and
'omarchy install ' usage prefixes and list those commands instead of
falling through to Unknown. Also drop the trailing ' ?' punctuation
from the 'Did you mean' line so the suggestion is a runnable command:
'omarchy install bogus' now suggests 'omarchy install', which shows
the Install group help, instead of looping on 'omarchy install ?'.
@greptile-apps

greptile-apps Bot commented Nov 19, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 5/5

[Low impact] The PR appears safe to merge; no new actionable issues were found.

Summary

The CLI now lists subgroup commands when help is requested and prints suggestions that safely open help.

  • Subgroup help requests list the matching commands.
  • Unknown-command suggestions open help when run.

Both previous findings are addressed. Targeted checks passed for subgroup help, unknown-command exit codes, and the migration help suggestion. Bash syntax checks also passed.

Reviews (2) · Last reviewed commit: "Suggest --help for unknown commands and ..." · Reviewed by Greptile

Comment thread bin/omarchy Resolved
Comment thread bin/omarchy Resolved
@omarchybot

Copy link
Copy Markdown
Collaborator

Source review by GPT-6 in Codex (high effort) supports Greptile’s migration finding: suggest_command can return migrate, so the new suggestion becomes omarchy migrate, whose default mode runs pending migrations. The new subgroup-help path also has no regression test in test/cli.

I classified this as a bug, but the classification check received no valid class from deepseek-v4p1-flash, so classification remains unsettled. No worker tests ran, no changes were pushed, and no labels were added. A code-review second opinion was not requested; the reviewer availability check succeeded. This is waiting for classification to be completed before verification and fixes can proceed.

@omarchybot

Copy link
Copy Markdown
Collaborator

Source review by GPT-6 in Codex (high effort) of 39bc0f6b1fece58235a7550a5e35c13fba161595 found that the earlier suggestions and coverage concerns are addressed in the diff: suggestions now include --help, and test/cli covers subgroup help and following suggestions without executing their target. I read the revised router, tests, previous review comments and the base branch’s command metadata rules. These changes have not been verified on a worker in this pass.

I classified this as a bug, but the configured classifier, deepseek-v4p1-flash, again returned no valid class. The workflow requires classification to be settled before verification can continue. No code-review second opinion was requested, no tests ran, no changes were pushed and no labels were added. This is waiting for classification to be completed.

@omarchybot

Copy link
Copy Markdown
Collaborator

The prefix help bug here is real: on quattro, omarchy theme bg lists its commands while omarchy theme bg --help exits 127, reproduced on an Omarchy ISO worker. Ten open pull requests fix it, and #19488 is the one being carried forward, because it changes prefix help and nothing else. It is verified on a worker and waiting on the maintainer.

What this one does beyond that fix: It changes the "Did you mean" line to end in --help, which is the one-line change #18811 was narrowed to before the maintainer closed it. It also treats a trailing ? as a help flag, which #18811 proposed too; unquoted, ? is a shell glob that expands to any one-character filename in the current directory. Most of the 38 added test lines cover the suggestion change rather than prefix help.

This pull request was read, not run. Reviewed by Claude Fable 5.2; the comparison of all ten diffs also went to Opus 5.5 High and muse-wonder via pi, thinking high, who reached the same choice and named the same points about this one. They could read my notes, so that agreement is not guaranteed to be independent. Nothing was pushed here. It is waiting on the maintainer, who decides whether to keep it open.

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

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants