[][src]Function envmnt::parse_env_file_content

pub fn parse_env_file_content(env_content: &str) -> IndexMap<String, String>

Parses the provided content as a map of key/value. The content should be in the form of an env file format.

Arguments

Example

fn main() {
    let env = envmnt::parse_env_file_content(r#"
    ENV_VAR1=1
    ENV_VAR2=2
    "#);

    println!("Parsed Env: {:?}", &env);
}