Skip to main content

Module cli

Module cli 

Source
Expand description

CLI surfaces for the firstpass binary (SPEC §7.3/§7.4): doctor validates a setup before you route real traffic through it, and trace reads recent audit records from the store. Both are kept here (not in the binary) so the judgment is unit-tested.

Structs§

Check
One line of the doctor report.
DoctorReport
The result of firstpass doctor.

Enums§

CheckStatus
A single doctor check outcome.

Functions§

command_on_path
Whether program is runnable: an explicit path (contains a separator) that exists, or a bare name found in one of PATH’s directories.
doctor
Validate a loaded config against the environment: routing sanity, provider key presence, and that every configured gate’s command actually exists. env looks up environment variables (injected so this is testable).
format_traces
Render the most recent limit traces as JSON lines — machine-first (SPEC §0.2): each line is a full Trace, newest last.