cli

package
v0.0.33 Latest Latest
Warning

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

Go to latest
Published: Jun 17, 2021 License: Apache-2.0 Imports: 42 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DefaultUsageFunc

func DefaultUsageFunc(sf *SortedFlags, c *ffcli.Command, deprecatedFields []string) string

This is mostly copied from ffcli package

func Start

func Start(cfg *config.Config) error

Types

type SortedFlags added in v0.0.21

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

SortedFlags is needed because by default there's no way to provide order for flags

this is kind of an ugly workaround

func NewSortedFlags added in v0.0.21

func NewSortedFlags(obj interface{}, fs *flag.FlagSet, deprecatedFields []string) *SortedFlags

func PopulateFlagSet added in v0.0.21

func PopulateFlagSet(obj interface{}, flagSet *flag.FlagSet, skip ...string) *SortedFlags

func (*SortedFlags) Len added in v0.0.21

func (sf *SortedFlags) Len() int

func (*SortedFlags) Less added in v0.0.21

func (sf *SortedFlags) Less(i, j int) bool

func (*SortedFlags) Swap added in v0.0.21

func (sf *SortedFlags) Swap(i, j int)

func (*SortedFlags) VisitAll added in v0.0.21

func (sf *SortedFlags) VisitAll(cb func(*flag.Flag))

Jump to

Keyboard shortcuts

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