Skip to main content

substitute_template

Function substitute_template 

Source
pub fn substitute_template(template: &str, unit_id: &str) -> String
Expand description

Replace {id} and {model} placeholders in a command template.

If model is Some, replaces {model} with the value. If model is None, {model} is left as-is (backward compatible).