Goal
Harden the fatal-guard CLI entry point for production use.
Context
fatal-guard has a CLI at bin/fatal-guard.js but it lacks:
- Consistent exit codes (0=success, 1=error, 2=usage)
- Helpful error messages when things fail
--help and --version flags
- Graceful handling of missing Node.js
- Timeout for hung processes
Scope
- Add
--help flag with usage examples
- Add
--version flag
- Define exit codes: 0=normal, 1=error caught, 2=usage error, 3=timeout
- Add
--timeout <ms> flag (default: 0 = no timeout)
- Improve error messages for common failures:
- Missing FATAL_HANDLER
- Invalid JSON output from handler
- Process not found
- Test all exit codes and error paths
Deliverable
fatal-guard --help shows usage
fatal-guard --version shows version
- Exit codes are consistent and documented
- Error messages are actionable
Labels
ready, agent-friendly, zero-bounty
This repo is using Opire - what does it mean? 👇
💵 Everyone can add rewards for this issue commenting /reward 100 (replace 100 with the amount).
🕵️♂️ If someone starts working on this issue to earn the rewards, they can comment /try to let everyone know!
🙌 And when they open the PR, they can comment /claim #1010 either in the PR description or in a PR's comment.
🪙 Also, everyone can tip any user commenting /tip 20 @Ikalus1988 (replace 20 with the amount, and @Ikalus1988 with the user to tip).
📖 If you want to learn more, check out our documentation.
Goal
Harden the fatal-guard CLI entry point for production use.
Context
fatal-guard has a CLI at
bin/fatal-guard.jsbut it lacks:--helpand--versionflagsScope
--helpflag with usage examples--versionflag--timeout <ms>flag (default: 0 = no timeout)Deliverable
fatal-guard --helpshows usagefatal-guard --versionshows versionLabels
ready, agent-friendly, zero-bounty
This repo is using Opire - what does it mean? 👇
💵 Everyone can add rewards for this issue commenting
/reward 100(replace100with the amount).🕵️♂️ If someone starts working on this issue to earn the rewards, they can comment
/tryto let everyone know!🙌 And when they open the PR, they can comment
/claim #1010either in the PR description or in a PR's comment.🪙 Also, everyone can tip any user commenting
/tip 20 @Ikalus1988(replace20with the amount, and@Ikalus1988with the user to tip).📖 If you want to learn more, check out our documentation.