cmd

package
v0.6.3 Latest Latest
Warning

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

Go to latest
Published: Sep 16, 2025 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

View Source
const AutoApplyWarningMessage = "# WARNING: Your file will be applied automatically once saved. If you do not want to apply anything, save an  empty file.\n"
View Source
const FILE_ARGS_DOC = "" /* 153-byte string literal not displayed */

Variables

View Source
var OutputFormatIds = map[OutputFormat][]string{
	JSON: {"json"},
	YAML: {"yaml"},
	NAME: {"name"},
}

Functions

func ApplyResources added in v0.6.0

func ApplyResources(resources []resource.Resource,
	applyFunc func(*resource.Resource, bool, bool) (client.Result, error),
	logFunc func(resource.Resource, client.Result, error),
	dryRun bool,
	diffMode bool,
	maxParallel int) []struct {
	Resource     resource.Resource
	UpsertResult client.Result
	Err          error
}

Globally accessible for testing purposes

func Execute

func Execute()

Execute adds all child commands to the root command and sets flags appropriately. This is called by main.main(). It only needs to happen once to the rootCmd.

Types

type MultipleFlags added in v0.4.0

type MultipleFlags struct {
	// contains filtered or unexported fields
}

func NewMultipleFlags added in v0.4.0

func NewMultipleFlags(command *cobra.Command, flagParams map[string]schema.FlagParameterOption) *MultipleFlags

func (*MultipleFlags) ExtractFlagValueForBodyParam added in v0.4.0

func (m *MultipleFlags) ExtractFlagValueForBodyParam() map[string]interface{}

func (*MultipleFlags) ExtractFlagValueForQueryParam added in v0.4.0

func (m *MultipleFlags) ExtractFlagValueForQueryParam() map[string]string

type OutputFormat added in v0.3.0

type OutputFormat enumflag.Flag
const (
	JSON OutputFormat = iota
	YAML
	NAME
)

func (OutputFormat) String added in v0.3.0

func (o OutputFormat) String() string

Jump to

Keyboard shortcuts

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