Documentation
¶
Overview ¶
Package env implements the functions, types, and interfaces for the module.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func LookupEnv ¶ added in v0.2.15
LookupEnv retrieves the value of an environment variable with the given key.
Types ¶
type Env ¶ added in v0.2.15
type Env interface {
// Var constructs a string by joining the given string slices with underscores and converting to uppercase.
Var(...string) string
// LookupEnv retrieves the value of an environment variable with the given key.
LookupEnv(string) (string, bool)
// SetEnv sets an environment variable with the given key and value.
SetEnv(string, string) error
// GetEnv retrieves the value of an environment variable with the given key.
GetEnv(string) string
}
Env is an interface that provides methods for working with environment variables. It includes methods for looking up, setting, and getting environment variables.
func WithPrefix ¶ added in v0.2.15
WithPrefix creates a new Env instance with the given prefix.
Click to show internal directories.
Click to hide internal directories.