Skip to main content

cli_render_help_with_options

Function cli_render_help_with_options 

Source
pub fn cli_render_help_with_options(
    cmd: &Command,
    subcommand_path: &[&str],
    options: &HelpOptions,
) -> String
Expand description

Render help for a clap command tree with explicit scope and format.

Walks to the subcommand identified by subcommand_path (empty = root), then renders either the selected command only (OneLevel) or the selected command and all descendants (Recursive).

Plain and Markdown are text. Json and Yaml are protocol-v1 terminal results (result.code:"help", model under result.help) — the same shape cli_handle_help_or_continue emits, so structured help validates against cli-help-v1.schema.json no matter which entry point produced it.

Requires the cli-help feature.