env

package
v1.0.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 30, 2025 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BuildArgsEnvMap

func BuildArgsEnvMap(
	args executable.ArgumentList,
	execArgs []string,
	env map[string]string,
) (map[string]string, error)

func BuildEnvMap

func BuildEnvMap(
	currentVault string,
	exec *executable.ExecutableEnvironment,
	args []string,
	inputEnv map[string]string,
	defaultEnv map[string]string,
) (map[string]string, error)

BuildEnvMap constructs a map of environment variables based on the executable parameters and arguments.

func CreateTempEnvFiles

func CreateTempEnvFiles(
	currentVault, flowfilePath, wsPath string,
	exec *executable.ExecutableEnvironment,
	args []string,
	promptedEnv map[string]string,
) (func(ctx *context.Context) error, error)

CreateTempEnvFiles creates temporary files for parameters and arguments that have an OutputFile defined. It returns a cleanup function that should be called to remove these files after use.

func DefaultEnv

func DefaultEnv(ctx *context.Context, executable *executable.Executable) map[string]string

func EnvListToEnvMap

func EnvListToEnvMap(envList []string) map[string]string

EnvListToEnvMap converts a slice of strings in the format "KEY=VALUE" to a map of environment variables.

func EnvMapToEnvList

func EnvMapToEnvList(envMap map[string]string) []string

EnvMapToEnvList converts a map of environment variables to a slice of strings in the format "KEY=VALUE".

func ResolveParameterValue

func ResolveParameterValue(
	currentVault string,
	param executable.Parameter,
	promptedEnv map[string]string,
) (string, error)

func SetEnv

func SetEnv(
	currentVault string,
	exec *executable.ExecutableEnvironment,
	args []string,
	promptedEnv map[string]string,
) error

SetEnv sets environment variables based on the parameters and arguments defined in the executable environment.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL