Skip to main content

handle_smart_init

Function handle_smart_init 

Source
pub fn handle_smart_init(
    template_arg: Option<&str>,
    force: bool,
    colors: Colors,
) -> Result<bool>
Expand description

Handle the smart --init flag using the default path resolver.

This is a convenience wrapper that uses RealConfigEnvironment internally.

§Arguments

  • template_arg - Optional template name from --init=TEMPLATE
  • force - If true, overwrite existing PROMPT.md without prompting
  • colors - Terminal color configuration for output

§Returns

Returns Ok(true) if the flag was handled (program should exit after), or Ok(false) if not handled, or an error if initialization failed.