pub fn load_filename<P: AsRef<Path>>(filename: P) -> Result<PathBuf>
Expand description

Load the given filename and then set environment variables.

It will search for the given filename in the current directory or its parents in sequence.

Examples

dotenv::load_filename(".env.local").ok();