Documentation ¶
Index ¶
- func BoolVarPF(f *pflag.FlagSet, p *bool, name, shorthand string, value bool, usage string) *pflag.Flag
- func BytesBase64Var(f *pflag.FlagSet, name string, value []byte, usage string) *[]byte
- func BytesBase64VarP(f *pflag.FlagSet, p *[]byte, name, shorthand string, value []byte, ...)
- func BytesBase64VarPF(f *pflag.FlagSet, p *[]byte, name, shorthand string, value []byte, ...) *pflag.Flag
- func IdentityPath(f *pflag.FlagSet, name string, value []map[string]string, usage string) *[]map[string]string
- func IdentityPathP(f *pflag.FlagSet, name, shorthand string, value []map[string]string, ...) *[]map[string]string
- func IdentityPathVar(f *pflag.FlagSet, p *[]map[string]string, name string, ...)
- func IdentityPathVarP(f *pflag.FlagSet, p *[]map[string]string, name, shorthand string, ...)
- func IdentityPathVarPF(f *pflag.FlagSet, p *[]map[string]string, name, shorthand string, ...) *pflag.Flag
- func IntVarPF(f *pflag.FlagSet, p *int, name, shorthand string, value int, usage string) *pflag.Flag
- func LabelledStringVarP(flags *pflag.FlagSet, p *LabelledString, name, shorthand string, ...)
- func LabelledStringVarPF(flags *pflag.FlagSet, p *LabelledString, name, shorthand string, ...) *pflag.Flag
- func LabelledValueVarP(flags *pflag.FlagSet, p *LabelledValue, name, shorthand string, ...)
- func LabelledValueVarPF(flags *pflag.FlagSet, p *LabelledValue, name, shorthand string, ...) *pflag.Flag
- func NewLabelledStringValue(val LabelledString, p *LabelledString) *labelledStringValue
- func Path(f *pflag.FlagSet, name string, value string, usage string) *string
- func PathArray(f *pflag.FlagSet, name string, value []string, usage string) *[]string
- func PathArrayP(f *pflag.FlagSet, name, shorthand string, value []string, usage string) *[]string
- func PathArrayVar(f *pflag.FlagSet, p *[]string, name string, value []string, usage string)
- func PathArrayVarP(f *pflag.FlagSet, p *[]string, name, shorthand string, value []string, ...)
- func PathArrayVarPF(f *pflag.FlagSet, p *[]string, name, shorthand string, value []string, ...) *pflag.Flag
- func PathP(f *pflag.FlagSet, name, shorthand string, value string, usage string) *string
- func PathVar(f *pflag.FlagSet, p *string, name string, value string, usage string)
- func PathVarP(f *pflag.FlagSet, p *string, name, shorthand string, value string, ...)
- func PathVarPF(f *pflag.FlagSet, p *string, name, shorthand string, value string, ...) *pflag.Flag
- func Semver(f *pflag.FlagSet, name string, value []*semver.Version, usage string) *[]*semver.Version
- func SemverConstraints(f *pflag.FlagSet, name string, value []*semver.Constraints, usage string) *[]*semver.Constraints
- func SemverConstraintsP(f *pflag.FlagSet, name, shorthand string, value []*semver.Constraints, ...) *[]*semver.Constraints
- func SemverConstraintsVar(f *pflag.FlagSet, p *[]*semver.Constraints, name string, ...)
- func SemverConstraintsVarP(f *pflag.FlagSet, p *[]*semver.Constraints, name, shorthand string, ...)
- func SemverConstraintsVarPF(f *pflag.FlagSet, p *[]*semver.Constraints, name, shorthand string, ...) *pflag.Flag
- func SemverP(f *pflag.FlagSet, name, shorthand string, value []*semver.Version, ...) *[]*semver.Version
- func SemverVar(f *pflag.FlagSet, p *[]*semver.Version, name string, value []*semver.Version, ...)
- func SemverVarP(f *pflag.FlagSet, p *[]*semver.Version, name, shorthand string, ...)
- func SemverVarPF(f *pflag.FlagSet, p *[]*semver.Version, name, shorthand string, ...) *pflag.Flag
- func StringArrayVarPF(f *pflag.FlagSet, p *[]string, name, shorthand string, value []string, ...) *pflag.Flag
- func StringColonStringSliceVar[T ~map[string][]string](f *pflag.FlagSet, p *T, name string, value map[string][]string, usage string)
- func StringColonStringSliceVarP[T ~map[string][]string](f *pflag.FlagSet, p *T, name, shorthand string, value map[string][]string, ...)
- func StringColonStringSliceVarPF[T ~map[string][]string](f *pflag.FlagSet, p *T, name, shorthand string, value map[string][]string, ...) *pflag.Flag
- func StringColonStringSliceVarPFA[T ~map[string][]string](f *pflag.FlagSet, p *T, name, shorthand string, value map[string][]string, ...) *pflag.Flag
- func StringToStringSliceVar[T ~map[string][]string](f *pflag.FlagSet, p *T, name string, value map[string][]string, usage string)
- func StringToStringSliceVarP[T ~map[string][]string](f *pflag.FlagSet, p *T, name, shorthand string, value map[string][]string, ...)
- func StringToStringSliceVarPF[T ~map[string][]string](f *pflag.FlagSet, p *T, name, shorthand string, value map[string][]string, ...) *pflag.Flag
- func StringToStringSliceVarPFA[T ~map[string][]string](f *pflag.FlagSet, p *T, name, shorthand string, value map[string][]string, ...) *pflag.Flag
- func StringToStringVar[T ~map[string]string](f *pflag.FlagSet, p *T, name string, value map[string]string, usage string)
- func StringToStringVarP[T ~map[string]string](f *pflag.FlagSet, p *T, name, shorthand string, value map[string]string, ...)
- func StringToStringVarPF[T ~map[string]string](f *pflag.FlagSet, p *T, name, shorthand string, value map[string]string, ...) *pflag.Flag
- func StringToStringVarPFA[T ~map[string]string](f *pflag.FlagSet, p *T, name, shorthand string, value map[string]string, ...) *pflag.Flag
- func StringToValue(f *pflag.FlagSet, name string, value map[string]interface{}, usage string) *map[string]interface{}
- func StringToValueP(f *pflag.FlagSet, name, shorthand string, value map[string]interface{}, ...) *map[string]interface{}
- func StringToValueVar(f *pflag.FlagSet, p *map[string]interface{}, name string, ...)
- func StringToValueVarP(f *pflag.FlagSet, p *map[string]interface{}, name, shorthand string, ...)
- func StringToValueVarPF(f *pflag.FlagSet, p *map[string]interface{}, name, shorthand string, ...) *pflag.Flag
- func StringVarPF(f *pflag.FlagSet, p *string, name, shorthand string, value string, ...) *pflag.Flag
- func YAMLVarP[T any](flags *pflag.FlagSet, p *T, name, shorthand string, value T, usage string)
- func YAMLVarPF[T any](flags *pflag.FlagSet, p *T, name, shorthand string, value T, usage string) *pflag.Flag
- type LabelledString
- type LabelledValue
- type LabelledValueValue
- type YAMLValue
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BoolVarPF ¶
func BoolVarPF(f *pflag.FlagSet, p *bool, name, shorthand string, value bool, usage string) *pflag.Flag
BoolVarPF is like BoolVarP, but returns the created flag.
func BytesBase64Var ¶
BytesBase64Var defines an []byte flag with specified name, default value, and usage string. The return value is the address of an []byte variable that stores the value of the flag.
func BytesBase64VarP ¶
func BytesBase64VarP(f *pflag.FlagSet, p *[]byte, name, shorthand string, value []byte, usage string)
BytesBase64VarP is like BytesBase64Var, but accepts a shorthand letter that can be used after a single dash.
func BytesBase64VarPF ¶
func IdentityPath ¶ added in v0.15.0
func IdentityPathP ¶ added in v0.15.0
func IdentityPathVar ¶ added in v0.15.0
func IdentityPathVarP ¶ added in v0.15.0
func IdentityPathVarPF ¶ added in v0.15.0
func IntVarPF ¶
func IntVarPF(f *pflag.FlagSet, p *int, name, shorthand string, value int, usage string) *pflag.Flag
IntVarPF is like IntVarP, but returns the created flag.
func LabelledStringVarP ¶
func LabelledStringVarP(flags *pflag.FlagSet, p *LabelledString, name, shorthand string, value LabelledString, usage string)
func LabelledStringVarPF ¶
func LabelledStringVarPF(flags *pflag.FlagSet, p *LabelledString, name, shorthand string, value LabelledString, usage string) *pflag.Flag
func LabelledValueVarP ¶
func LabelledValueVarP(flags *pflag.FlagSet, p *LabelledValue, name, shorthand string, value LabelledValue, usage string)
func LabelledValueVarPF ¶
func LabelledValueVarPF(flags *pflag.FlagSet, p *LabelledValue, name, shorthand string, value LabelledValue, usage string) *pflag.Flag
func NewLabelledStringValue ¶
func NewLabelledStringValue(val LabelledString, p *LabelledString) *labelledStringValue
func Path ¶
Path defines a filepath flag with specified name, default value, and usage string. The return value is the address of a string variable that stores the value of the flag.
func PathArray ¶
PathArray defines a filepath flag with specified name, default value, and usage string. The return value is the address of a []string variable that stores the value of the flag.
func PathArrayP ¶
PathArrayP is like PathArray, but accepts a shorthand letter that can be used after a single dash.
func PathArrayVar ¶
PathArrayVar defines a filepath flag with specified name, default value, and usage string. The argument p points to a []string variable in which to store the values of the multiple flags.
func PathArrayVarP ¶
func PathArrayVarP(f *pflag.FlagSet, p *[]string, name, shorthand string, value []string, usage string)
PathArrayVarP is like PathArrayVar, but accepts a shorthand letter that can be used after a single dash.
func PathArrayVarPF ¶
func PathArrayVarPF(f *pflag.FlagSet, p *[]string, name, shorthand string, value []string, usage string) *pflag.Flag
PathArrayVarPF is like PathArrayVarP, but returns the created flag.
func PathP ¶
PathP is like Path, but accepts a shorthand letter that can be used after a single dash.
func PathVar ¶
PathVar defines a filepath flag with specified name, default value, and usage string. The argument p points to a string variable in which to store the value of the flag.
func PathVarP ¶
PathVarP is like PathVar, but accepts a shorthand letter that can be used after a single dash.
func PathVarPF ¶
func PathVarPF(f *pflag.FlagSet, p *string, name, shorthand string, value string, usage string) *pflag.Flag
PathVarPF is like PathVarP, but returns the created flag.
func SemverConstraints ¶
func SemverConstraintsP ¶
func SemverConstraintsVar ¶
func SemverConstraintsVarP ¶
func SemverConstraintsVarPF ¶
func SemverVarP ¶
func SemverVarPF ¶
func StringArrayVarPF ¶
func StringArrayVarPF(f *pflag.FlagSet, p *[]string, name, shorthand string, value []string, usage string) *pflag.Flag
StringArrayVarPF is like StringArrayVarP, but returns the created flag.
func StringColonStringSliceVar ¶
func StringColonStringSliceVar[T ~map[string][]string](f *pflag.FlagSet, p *T, name string, value map[string][]string, usage string)
StringColonStringSliceVar defines a string flag with specified name, default value, and usage string. The argument p points to a map[string][]string variable in which to store the values of the multiple flags.
func StringColonStringSliceVarP ¶
func StringColonStringSliceVarP[T ~map[string][]string](f *pflag.FlagSet, p *T, name, shorthand string, value map[string][]string, usage string)
StringColonStringSliceVarP is like StringColonStringSliceVar, but accepts a shorthand letter that can be used after a single dash.
func StringColonStringSliceVarPF ¶
func StringColonStringSliceVarPF[T ~map[string][]string](f *pflag.FlagSet, p *T, name, shorthand string, value map[string][]string, usage string) *pflag.Flag
StringColonStringSliceVarPF is like StringColonStringSliceVarP, but returns the created flag.
func StringColonStringSliceVarPFA ¶
func StringColonStringSliceVarPFA[T ~map[string][]string](f *pflag.FlagSet, p *T, name, shorthand string, value map[string][]string, usage string) *pflag.Flag
StringColonStringSliceVarPFA is like StringColonStringSliceVarPF, but allows to add to a preset map.
func StringToStringSliceVar ¶
func StringToStringSliceVar[T ~map[string][]string](f *pflag.FlagSet, p *T, name string, value map[string][]string, usage string)
StringToStringSliceVar defines a string flag with specified name, default value, and usage string. The argument p points to a map[string][]string variable in which to store the values of the multiple flags.
func StringToStringSliceVarP ¶
func StringToStringSliceVarP[T ~map[string][]string](f *pflag.FlagSet, p *T, name, shorthand string, value map[string][]string, usage string)
StringToStringSliceVarP is like StringToStringVar, but accepts a shorthand letter that can be used after a single dash.
func StringToStringSliceVarPF ¶
func StringToStringSliceVarPF[T ~map[string][]string](f *pflag.FlagSet, p *T, name, shorthand string, value map[string][]string, usage string) *pflag.Flag
StringToStringSliceVarPF is like StringToStringVarP, but returns the created flag.
func StringToStringSliceVarPFA ¶
func StringToStringSliceVarPFA[T ~map[string][]string](f *pflag.FlagSet, p *T, name, shorthand string, value map[string][]string, usage string) *pflag.Flag
StringToStringSliceVarPFA is like StringToStringVarPF, but allows to add to a preset map.
func StringToStringVar ¶
func StringToStringVar[T ~map[string]string](f *pflag.FlagSet, p *T, name string, value map[string]string, usage string)
StringToStringVar defines a string flag with specified name, default value, and usage string. The argument p points to a map[string]string variable in which to store the values of the multiple flags. The value of each argument will not try to be separated by comma.
func StringToStringVarP ¶
func StringToStringVarP[T ~map[string]string](f *pflag.FlagSet, p *T, name, shorthand string, value map[string]string, usage string)
StringToStringVarP is like StringToStringVar, but accepts a shorthand letter that can be used after a single dash.
func StringToStringVarPF ¶
func StringToStringVarPF[T ~map[string]string](f *pflag.FlagSet, p *T, name, shorthand string, value map[string]string, usage string) *pflag.Flag
StringToStringVarPF is like StringToStringVarP, but returns the created flag.
func StringToStringVarPFA ¶
func StringToStringVarPFA[T ~map[string]string](f *pflag.FlagSet, p *T, name, shorthand string, value map[string]string, usage string) *pflag.Flag
StringToStringVarPFA is like StringToStringVarPF, but allows to add to a preset map.
func StringToValue ¶
func StringToValueP ¶
func StringToValueVar ¶
func StringToValueVarP ¶
func StringToValueVarPF ¶
func StringVarPF ¶
func StringVarPF(f *pflag.FlagSet, p *string, name, shorthand string, value string, usage string) *pflag.Flag
StringVarPF is like StringVarP, but returns the created flag.
Types ¶
type LabelledString ¶
type LabelledValue ¶
type LabelledValue struct { Name string Value interface{} }
type LabelledValueValue ¶
type LabelledValueValue LabelledValue
func NewLabelledValueValue ¶
func NewLabelledValueValue(val LabelledValue, p *LabelledValue) *LabelledValueValue
func (*LabelledValueValue) Set ¶
func (i *LabelledValueValue) Set(s string) error
func (*LabelledValueValue) String ¶
func (i *LabelledValueValue) String() string
func (*LabelledValueValue) Type ¶
func (i *LabelledValueValue) Type() string
type YAMLValue ¶
type YAMLValue[T any] struct { // contains filtered or unexported fields }