mirror of
https://github.com/instructkr/claw-code.git
synced 2026-04-07 00:24:50 +08:00
Promote doctor into a real top-level CLI action, reuse the same local report for resumed and REPL doctor invocations, and intercept doctor/status/sandbox help flags before prompt-mode dispatch. The parser change also closes the help fallthrough that previously wandered into runtime startup for local-info commands. Constraint: Preserve prompt shorthand for normal multi-word text input while fixing exact local subcommand help paths Rejected: Route \7[1G[2K[m⠋ 🦀 Thinking...[0m8[1G[2K[m✘ ❌ Request failed [0m through prompt/slash guidance | still shells out through the wrong surface and keeps health checks hidden Rejected: Reuse the status report as doctor output | status does not explain auth/config health or expose a dedicated diagnostic summary Confidence: high Scope-risk: narrow Directive: Keep doctor local-only unless an explicit network probe is intentionally added and separately tested Tested: cargo build -p rusty-claude-cli; cargo test -p rusty-claude-cli; cargo run -p rusty-claude-cli -- doctor --help; CLAW_CONFIG_HOME=/tmp/tmp.7pm9SVzOPN ANTHROPIC_API_KEY= ANTHROPIC_AUTH_TOKEN= cargo run -p rusty-claude-cli -- doctor Not-tested: direct /doctor outside the REPL remains interactive-only