/// Creates a specific license string from a specified template.
Creates a specific license string from a specified template.
Creates a specific license string from a specified template .
fn create_license(&self, license: &str) -> Result<String> {
        let template_path = get_template_path(license)
            .with_context(|| format!("Template `{}.txt` does not exist.", license))?;
        let template_file = read_to_string(template_path)?;
        let formatted_file = self.search_and_replace(template_file);
        Ok(formatted_file)
    }
fn create_license ( & self , license : & str ) -> Result < String > { let template_path = get_template_path ( license ) . with_context ( | | format ! ( " " license ) ) ? ; let template_file = read_to_string ( template_path ) ? ; let formatted_file = self . search_and_replace ( template_file ) ; Ok ( formatted_file ) }
Creates a specific license string from a specified template.
Creates a specific license string from a specified template .
&self
license
&str