Documentation
¶
Overview ¶
Package env provides helpers for reading earth's environment variables, including backwards-compatible support for the deprecated EARTHLY_ prefix.
Index ¶
Constants ¶
const DeprecatedPrefix = "EARTHLY_"
DeprecatedPrefix is the legacy environment variable prefix that is being replaced by Prefix.
const Prefix = "EARTH_"
Prefix is the current environment variable prefix.
Variables ¶
This section is empty.
Functions ¶
func DeprecatedWarnings ¶
func DeprecatedWarnings() []string
DeprecatedWarnings returns a deprecation warning message for each DeprecatedPrefix-prefixed variable present in the current environment, sorted for deterministic output.
NOTE: This is a temporary shim to support the EARTHLY_ -> EARTH_ migration. Remove it (and its tests) once EARTHLY_ support is officially dropped.
func Lookup ¶
Lookup returns the value of the environment variable identified by suffix, preferring the current Prefix and falling back to the deprecated DeprecatedPrefix.
NOTE: the DeprecatedPrefix fallback is a temporary shim to support the EARTHLY_ -> EARTH_ migration; drop it once EARTHLY_ support is officially removed.
Types ¶
This section is empty.