Documentation ¶
Index ¶
- Variables
- func FetchEncryptedEnv(envKey string, keeper *crypt.Keeper, obj any) error
- func FetchEnv(envKey string, obj any) error
- func FetchLastEnv(diffKey string, keeper *crypt.Keeper) (config.Env, error)
- func FetchRevert(envKey string) (map[string]*string, error)
- func IgnoredEnv(key string) bool
- func LoadEnv(gzenvStr string, data any) (err error)
- type EnvDiff
Constants ¶
This section is empty.
Variables ¶
View Source
var IgnoredKeys = map[string]bool{ "COMP_WORDBREAKS": true, "PS1": true, "OLDPWD": true, "PWD": true, "SHELL": true, "SHELLOPTS": true, "SHLVL": true, "_": true, }
IgnoredKeys is list of keys we don't want to deal with
Functions ¶
func FetchRevert ¶
FetchRevert undoes the recorded changes (if any) to the supplied environment, returning a new environment
func IgnoredEnv ¶
IgnoredEnv returns true if the key should be ignored in environment diffs.
Types ¶
type EnvDiff ¶
EnvDiff represents the diff between two environments
func BuildEnvDiff ¶
BuildEnvDiff analyses the changes between 'e1' and 'e2' and builds an EnvDiff out of it.
func LoadEnvDiff ¶
LoadEnvDiff unmarshalls a gzenv string back into an EnvDiff.
func (*EnvDiff) Patch ¶
Patch applies the diff to the given env and returns a new env with the changes applied.
Click to show internal directories.
Click to hide internal directories.