Documentation ¶
Index ¶
- func AreEnvVarsConsistent(envVars EnvVars) error
- func AreEnvVarsExportedAndSet(keys []string) error
- func AreEnvVarsSet(keys []string) error
- func DirExist(dir string) error
- func DirIsNotEmpty(dir string) error
- func DirIsValid(dir string) error
- func DoEnvVarsExist(keys []string) error
- func FileExist(filePath string) error
- func GetEnvVarsFromDotFile(filepath string) (map[string]string, error)
- func IsGitRepository(path string, checkUntilRoot bool, checkRecursivelyUntilIsFound bool) (string, error)
- func IsPathAbsolute(path string) error
- func IsPathRelative(path string) error
- func IsRelativeChildPath(parentPath string, childPath string) error
- func IsSubDir(parentDir string, childDir string) error
- func PathExist(path string) (os.FileInfo, error)
- func PathIsADirectory(path string) error
- func PathToAbsolute(path string) (string, error)
- type EnvVars
- func FetchAWSEnvVars() (EnvVars, error)
- func FetchAllEnvVarsFromHost() (EnvVars, error)
- func FetchEnvVarsAsMap(keys []string, optionalKeys []string) (EnvVars, error)
- func FetchEnvVarsWithPrefix(prefix string) (EnvVars, error)
- func MergeEnvVars(envVars ...EnvVars) EnvVars
- func ScanAWSCredentialsEnvVars() (EnvVars, error)
- func ScanEnvVarsFromPrefixes(prefixes []string) (EnvVars, error)
- func ScanTerraformEnvVars() (EnvVars, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AreEnvVarsConsistent ¶
AreEnvVarsConsistent checks if the environment variables have non-empty values.
func AreEnvVarsExportedAndSet ¶
AreEnvVarsExportedAndSet IsEnvVarSetOrExported checks if the environment variable exist, and also if it is exported or set.
func AreEnvVarsSet ¶
AreEnvVarsSet checks if the environment variables have non-empty values.
func DirIsNotEmpty ¶
func DirIsValid ¶
func DoEnvVarsExist ¶
DoEnvVarsExist checks if the environment variables exist.
func GetEnvVarsFromDotFile ¶ added in v0.2.2
func IsGitRepository ¶ added in v0.2.7
func IsPathAbsolute ¶ added in v0.2.4
func IsPathRelative ¶ added in v0.2.7
func IsRelativeChildPath ¶ added in v0.2.7
func PathIsADirectory ¶
func PathToAbsolute ¶
Types ¶
type EnvVars ¶
func FetchAWSEnvVars ¶
FetchAWSEnvVars fetches environment variables that start with the prefix "AWS_"
func FetchAllEnvVarsFromHost ¶ added in v0.2.2
func FetchEnvVarsAsMap ¶
FetchEnvVarsAsMap checks if the environment variables exist and returns them as a map.
func FetchEnvVarsWithPrefix ¶
FetchEnvVarsWithPrefix fetches environment variables that start with the specified prefix and returns an error if any of the variables either do not exist or have an empty value.
func MergeEnvVars ¶
func ScanAWSCredentialsEnvVars ¶
ScanAWSCredentialsEnvVars scans the environment variables for AWS credentials.
func ScanEnvVarsFromPrefixes ¶ added in v0.2.8
ScanEnvVarsFromPrefixes scans the environment variables for the specified prefixes.
func ScanTerraformEnvVars ¶
ScanTerraformEnvVars fetches environment variables that start with the prefix "TF_VAR_"