cmdutil

package
v0.0.0-...-da48874 Latest Latest
Warning

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

Go to latest
Published: Apr 4, 2023 License: Apache-2.0 Imports: 28 Imported by: 0

Documentation

Index

Constants

View Source
const (
	OutputFormatWide = "wide"
	OutputFormatCSV  = "csv"
)

Variables

This section is empty.

Functions

func Add

func Add(root *cobra.Command, sub *cobra.Command) *cobra.Command

func Bind

func Bind(root *cobra.Command, subs ...*cobra.Command) *cobra.Command

func NewConnection

func NewConnection(f *factory.Factory) (connection.Connection, error)

func NewFactory

func NewFactory() (*factory.Factory, error)

func PromptConfirm

func PromptConfirm(format string, args ...interface{}) (bool, error)

func ValidOutputs

func ValidOutputs() []string

func ValidateOutputs

func ValidateOutputs(cmd *cobra.Command) error

Types

type FlagOptions

type FlagOptions struct {
	Required func() *FlagOptions
	Complete func(func(*cobra.Command, []string, string) ([]string, cobra.ShellCompDirective)) *FlagOptions
}

FlagOptions defines additional flag options

func AddAllPages

func AddAllPages(cmd *cobra.Command, output *bool) *FlagOptions

func AddChannelUpdate

func AddChannelUpdate(cmd *cobra.Command, output *bool) *FlagOptions

func AddClusterID

func AddClusterID(cmd *cobra.Command, output *string) *FlagOptions

func AddDanglingDeployments

func AddDanglingDeployments(cmd *cobra.Command, output *bool) *FlagOptions

func AddFile

func AddFile(cmd *cobra.Command, output *string) *FlagOptions

func AddForce

func AddForce(cmd *cobra.Command, output *bool) *FlagOptions

func AddID

func AddID(cmd *cobra.Command, output *string) *FlagOptions

func AddLimit

func AddLimit(cmd *cobra.Command, output *int) *FlagOptions

func AddName

func AddName(cmd *cobra.Command, output *string) *FlagOptions

func AddNamespaceID

func AddNamespaceID(cmd *cobra.Command, output *string) *FlagOptions

func AddOperatorId

func AddOperatorId(cmd *cobra.Command, output *string) *FlagOptions

func AddOperatorUpdate

func AddOperatorUpdate(cmd *cobra.Command, output *bool) *FlagOptions

func AddOrderBy

func AddOrderBy(cmd *cobra.Command, output *string) *FlagOptions

func AddOutput

func AddOutput(cmd *cobra.Command, output *string) *FlagOptions

func AddPage

func AddPage(cmd *cobra.Command, output *int) *FlagOptions

func AddRevision

func AddRevision(cmd *cobra.Command, output *int64) *FlagOptions

func AddSearch

func AddSearch(cmd *cobra.Command, output *string) *FlagOptions

func AddTenantID

func AddTenantID(cmd *cobra.Command, output *string) *FlagOptions

func AddTenantKind

func AddTenantKind(cmd *cobra.Command, output *string) *FlagOptions

func AddUse

func AddUse(cmd *cobra.Command, output *bool) *FlagOptions

func AddYes

func AddYes(cmd *cobra.Command, yes *bool) *FlagOptions

type OutputWriter

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

func NewOutputFileWriter

func NewOutputFileWriter(path string) (*OutputWriter, error)

func NewOutputWriter

func NewOutputWriter(delegate io.Writer) (*OutputWriter, error)

func (*OutputWriter) Close

func (in *OutputWriter) Close() error

func (*OutputWriter) Write

func (in *OutputWriter) Write(p []byte) (n int, err error)

Jump to

Keyboard shortcuts

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