pub fn emit<T>(
cli: &Cli,
cfg: Option<&RepoConfig>,
out: &T,
) -> Result<(), Error>where
T: RenderOutput,Expand description
Resolve the format decision (JSON vs text) and emit accordingly.
Centralises the should_output_json → branch → write idiom from the
existing structure-first verbs. Handlers should construct a typed
output value and call this; never println! directly.