Documentation ¶
Index ¶
- func GetEnv(variableName string) (string, error)
- func GetEnvBool(variableName string) (bool, error)
- func GetEnvBoolOrDefault(variableName string, defaultValue bool) bool
- func GetEnvInt(variableName string) (int, error)
- func GetEnvIntOrDefault(variableName string, defaultValue int) int
- func GetEnvOrDefault(variableName string, defaultValue string) string
- func LoadDefaultEnvFile()
- func LoadEnvFile(envFilePath string)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetEnv ¶
GetEnv returns a string value of the environment variable name provided. It returns an error in the event of the variable not existing.
func GetEnvBool ¶
GetEnvBool returns a bool value of the environment variable name provided. It returns an error in the event of the variable not existing or parsing error.
func GetEnvBoolOrDefault ¶
GetEnvBoolOrDefault returns a bool value of the environment variable name provided. In case there is an error, or the variable doesn't exist, it will return the default provided value.
func GetEnvInt ¶
GetEnvInt returns an int value of the environment variable name provided. It returns an error in the event of the variable not existing or parsing error.
func GetEnvIntOrDefault ¶
GetEnvIntOrDefault returns an int value of the environment variable name provided. In case there is an error, or the variable doesn't exist, it will return the default provided value.
func GetEnvOrDefault ¶
GetEnvOrDefault returns a string value of the environment variable name provided. In case there is an error, or the variable doesn't exist, it will return the default provided value.
func LoadDefaultEnvFile ¶
func LoadDefaultEnvFile()
func LoadEnvFile ¶
func LoadEnvFile(envFilePath string)
Types ¶
This section is empty.