Documentation ¶
Overview ¶
Package flags holds common flags that are shared between our commands.
Index ¶
- func Merge(dst, src *flag.FlagSet)
- func ToSet(s []string) mapset.Set
- func Usage(txt string, flags *flag.FlagSet) string
- type AppendSliceValue
- type FlagMapValue
- type HTTPFlags
- func (f *HTTPFlags) APIClient() (*api.Client, error)
- func (f *HTTPFlags) Addr() string
- func (f *HTTPFlags) Flags() *flag.FlagSet
- func (f *HTTPFlags) MergeOntoConfig(c *api.Config)
- func (f *HTTPFlags) ReadTokenFile() (string, error)
- func (f *HTTPFlags) SetToken(v string) error
- func (f *HTTPFlags) SetTokenFile(v string) error
- func (f *HTTPFlags) Token() string
- func (f *HTTPFlags) TokenFile() string
- type K8SFlags
- type StringValue
- type Usager
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type AppendSliceValue ¶ added in v0.17.0
type AppendSliceValue []string
AppendSliceValue implements the flag.Value interface and allows multiple calls to the same variable to append a list.
func (*AppendSliceValue) Set ¶ added in v0.17.0
func (s *AppendSliceValue) Set(value string) error
func (*AppendSliceValue) String ¶ added in v0.17.0
func (s *AppendSliceValue) String() string
type FlagMapValue ¶ added in v0.26.0
FlagMapValue is a flag implementation used to provide key=value semantics multiple times.
func (*FlagMapValue) Set ¶ added in v0.26.0
func (h *FlagMapValue) Set(value string) error
func (*FlagMapValue) String ¶ added in v0.26.0
func (h *FlagMapValue) String() string
type HTTPFlags ¶ added in v0.17.0
type HTTPFlags struct {
// contains filtered or unexported fields
}
HTTPFlags are flags used to configure communication with a Consul agent.
func (*HTTPFlags) MergeOntoConfig ¶ added in v0.17.0
func (*HTTPFlags) ReadTokenFile ¶ added in v0.17.0
func (*HTTPFlags) SetTokenFile ¶ added in v0.17.0
type K8SFlags ¶
type K8SFlags struct {
// contains filtered or unexported fields
}
func (*K8SFlags) KubeConfig ¶
type StringValue ¶ added in v0.17.0
type StringValue struct {
// contains filtered or unexported fields
}
StringValue provides a flag value that's aware if it has been set.
func (*StringValue) Merge ¶ added in v0.17.0
func (s *StringValue) Merge(onto *string)
Merge will overlay this value if it has been set.
func (*StringValue) Set ¶ added in v0.17.0
func (s *StringValue) Set(v string) error
Set implements the flag.Value interface.
func (*StringValue) String ¶ added in v0.17.0
func (s *StringValue) String() string
String implements the flag.Value interface.
Click to show internal directories.
Click to hide internal directories.