Expand description
A well-maintained fork of the dotenv
crate
This library loads environment variables from a .env file. This is convenient for dev environments.
Structs§
Enums§
Functions§
- dotenv
- Loads the .env file from the current directory or parents. This is typically what you want.
- dotenv_
iter - Returns an iterator over environment variables.
- dotenv_
override - Loads all variables found in the
reader
into the environment, overriding any existing environment variables of the same name. - from_
filename - Loads environment variables from the specified file.
- from_
filename_ iter - Returns an iterator over environment variables from the specified file.
- from_
filename_ override - Loads environment variables from the specified file, overriding existing environment variables.
- from_
path - Loads environment variables from the specified path.
- from_
path_ iter - Returns an iterator over environment variables from the specified path.
- from_
path_ override - Loads environment variables from the specified path, overriding existing environment variables.
- from_
read - Loads environment variables from
io::Read
. - from_
read_ iter - Returns an iterator over environment variables from
io::Read
. - from_
read_ override - Loads environment variables from
io::Read
, overriding existing environment variables. - var
- Gets the value for an environment variable.
- vars
- Returns an iterator of
(key, value)
pairs for all environment variables of the current process. The returned iterator contains a snapshot of the process’s environment variables at the time of invocation. Modifications to environment variables afterwards will not be reflected.