options

package
v0.1.0-beta.1 Latest Latest
Warning

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

Go to latest
Published: Feb 17, 2026 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GlobalOptions

type GlobalOptions struct {
	// Configuration
	ConfigFile string
	Verbose    bool
	Debug      bool
	Strict     bool

	// Output options
	Output     string
	OutputFile string
	NoHeaders  bool
	ShowLabels bool
	Wide       bool

	// Common flags
	DryRun    bool
	Namespace string
}

GlobalOptions contains global flags and configuration

func NewGlobalOptions

func NewGlobalOptions() *GlobalOptions

NewGlobalOptions creates a new GlobalOptions with defaults

func (*GlobalOptions) AddFlags

func (o *GlobalOptions) AddFlags(flags *pflag.FlagSet)

AddFlags adds global flags to the provided FlagSet

func (*GlobalOptions) Complete

func (o *GlobalOptions) Complete() error

Complete completes the global options by reading from configuration

func (*GlobalOptions) IsJSONOutput

func (o *GlobalOptions) IsJSONOutput() bool

IsJSONOutput returns true if output format is JSON

func (*GlobalOptions) IsTableOutput

func (o *GlobalOptions) IsTableOutput() bool

IsTableOutput returns true if output format requires table formatting

func (*GlobalOptions) IsYAMLOutput

func (o *GlobalOptions) IsYAMLOutput() bool

IsYAMLOutput returns true if output format is YAML

func (*GlobalOptions) Validate

func (o *GlobalOptions) Validate() error

Validate validates the global options

Jump to

Keyboard shortcuts

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