Skip to main content

load_toml_config

Function load_toml_config 

Source
pub fn load_toml_config<T: DeserializeOwned>(
    path: &Path,
    template: Option<&str>,
) -> Result<T>
Expand description

Load a TOML config file and deserialize it into T.

If the file doesn’t exist and template is provided, writes the template to the path first, then loads it.