Skip to main content

run_command

Function run_command 

Source
pub async fn run_command(
    cli: Cli,
    config: &ClientConfig,
    format: OutputFormat,
) -> Result<()>
Expand description

Dispatch a parsed Cli to the requested subcommand.

Takes an already-loaded config and already-resolved format rather than loading the config itself, so a config-load failure (handled by the caller, lib::run) can be reported in the right format even before this function would otherwise learn the config file’s output key.