Repository navigation
Show usage for -h and --help in omarchy-crash-mute - #19496
ThePrimeagen wants to merge 2 commits into
Conversation
When invoked directly, omarchy-crash-mute never checked $1 for a help flag, so --help/-h fell through to the program path and were muted via omarchy-toggle. Add the same -h/--help check used by other bin scripts, reusing the existing usage() helper and exiting 0 before the "--" separator is stripped, so --help/-h print usage with no state change while -- -h still mutes a program named -h. The prior ISO build failure was unrelated to this change (network timeout downloading linux-t2-headers and a missing omarchy-settings-dev package), so the change is left as-is.
[Low impact] The PR appears safe to merge. Summary
Reviews (3) · Last reviewed commit: "Add regression test for -h and --help in..." · Reviewed by Greptile |
|
I read the change, its callers, the existing crash-capture tests, and Greptile’s missing-coverage finding at PR #19291 also addresses direct option arguments to this command, using rejection rather than successful help handling. That overlap still needs comparison once classification is settled. This item is waiting for classification to be completed. |
|
I read the updated head GPT-6 in Codex (reasoning effort not exposed) classified this as a bug fix, but the configured classification model, deepseek-v4p1-flash, again returned no valid class. Classification remains unsettled; no labels or code changes were applied, and a code-review second opinion was not requested. This item is waiting for classification to be completed. |
|
Reviewed by Claude Fable 5.2 at The bug is real. On a worker built from the Omarchy ISO, on
Two things noted and left as they are: the usage goes to stderr, so #19291 is an older open pull request for the same symptom and takes the other approach: it refuses any dash-leading name given without |
|
I compared #19291 also rejects unescaped option arguments such as No code was pushed and no new worker tests ran because the older competing fix is advancing. This head’s CI passes; its previous worker verification remains recorded. This PR stays open and waits on the maintainer while that handoff is worked. |
Fold #19496's successful help handling into the broader option guard. Check help before consuming -- so escaped program names remain literal, and distinguish help from invalid options in the regression checks. Co-Authored-By: ThePrimeagen <the.primeagen@gmail.com> Co-Authored-By: GPT-6 in Codex (reasoning effort not exposed) <noreply@openai.com>
Running
omarchy-crash-mute --helpin a terminal does not show help. Inbin/omarchy-crash-muteit prints "Muted crash notifications for --help.", mutes a program called--help, and leaves it in the mute list.Screenshots
Reproduce
omarchy-crash-mute --helpand press Enter.omarchy-crash-muteand press Enter.--helpas a muted program.More cases
Direct -h treated as a program
--help pollutes the mute list on the next run
Related
omarchy-crash-mutewithout direct help handling-h/--helppattern fixed inomarchy-tailscale-send-h/--helppattern fixed inomarchy-notification-send