Crate zenv[−][src]
Expand description
Zenv is a dotenv loader which parses and loads your environment variables from a .env
file.
This crate also supports variable substitution inside your .env file, if not found then tries to fetch from the running operating system. By default, this is disabled.
This crate only meant to use inside a development environment.
Example
use zenv::{zenv, Zenv};
fn main() {
Zenv::new(".env", false).configure().ok();
// is equivalent to
zenv!();
// with other file
zenv!(".env.development");
// or with variable substitution
zenv!(".env.development", true);
}
Macros
Structs
To collect the info about the current line
Lines
is used to parse the sequence of lines
Use this to load and configure the environment variables