stack

package
v0.83.2 Latest Latest
Warning

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

Go to latest
Published: Jul 14, 2025 License: MIT Imports: 19 Imported by: 1

Documentation

Overview

Package stack provides the command to stack.

Index

Constants

View Source
const (
	// CommandName stack command name.
	CommandName          = "stack"
	OutputFormatFlagName = "format"
	JSONFormatFlagName   = "json"
	RawFormatFlagName    = "raw"
	NoStackValidate      = "no-stack-validate"
)

Variables

This section is empty.

Functions

func FilterOutputs added in v0.72.9

func FilterOutputs(outputs cty.Value, index string) cty.Value

FilterOutputs filters the outputs based on the provided index key.

func NewCommand

func NewCommand(l log.Logger, opts *options.TerragruntOptions) *cli.Command

NewCommand builds the command for stack.

func PrintJSONOutput added in v0.72.9

func PrintJSONOutput(writer io.Writer, outputs cty.Value) error

PrintJSONOutput formats outputs as pretty-printed JSON with 2-space indentation. It marshals the cty.Value data to JSON using the go-cty library and writes the formatted result to the provided writer.

func PrintOutputs added in v0.72.9

func PrintOutputs(writer io.Writer, outputs cty.Value) error

PrintOutputs formats outputs as HCL and writes them to the provided writer. It creates a new HCL file with each top-level output as an attribute, preserving the original structure of complex types like maps and objects.

func PrintRawOutputs added in v0.72.9

func PrintRawOutputs(_ *options.TerragruntOptions, writer io.Writer, outputs cty.Value) error

PrintRawOutputs formats outputs for raw output format, similar to Tofu's output -raw. When the output is a raw output for a specific path, it will extract the raw value without quotes or formatting and write it directly to the provided writer. It only supports primitive values (strings, numbers, and booleans) and will return an error for complex types.

func Run added in v0.72.2

Run execute stack command.

func RunClean added in v0.73.1

func RunClean(ctx context.Context, l log.Logger, opts *options.TerragruntOptions) error

RunClean recursively removes all stack directories under the specified WorkingDir.

func RunGenerate

func RunGenerate(ctx context.Context, l log.Logger, opts *options.TerragruntOptions) error

RunGenerate runs the stack command.

func RunOutput added in v0.72.9

func RunOutput(ctx context.Context, l log.Logger, opts *options.TerragruntOptions, index string) error

RunOutput stack output.

Types

This section is empty.

Jump to

Keyboard shortcuts

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