Documentation
¶
Index ¶
- func Getenv(key string, def string) string
- func GetenvBool(key string, def bool) (bool, error)
- func GetenvFloat64(key string, def float64) (float64, error)
- func GetenvInt64(key string, def int64) (int64, error)
- func GetenvStringSlice(key string, def []string) []string
- func HasEnv(key string) bool
- func MustHasEnv(key string)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetenvBool ¶
GetenvBool wraps os.Getenv and returns a bool or the given default if empty or not defined.
func GetenvFloat64 ¶ added in v0.0.2
GetenvFloat64 wraps os.Getenv and returns an int or the given default if empty or not defined.
func GetenvInt64 ¶ added in v0.0.2
GetenvInt64 wraps os.Getenv and returns an int or the given default if empty or not defined.
func GetenvStringSlice ¶ added in v0.0.2
GetenvStringSlice wraps os.Getenv and returns a string slice or the given default if empty or not defined.
func MustHasEnv ¶ added in v0.0.2
func MustHasEnv(key string)
MustHasEnv panics if the given env var does not exists.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.