Documentation ¶ Index ¶ type Bool func (f *Bool) AddTo(cmds ...*cobra.Command) func (f *Bool) Get(cmd *cobra.Command, nonnull bool) *bool type Flag func (f *Flag) Changed(cmd *cobra.Command) bool type Flags func (fs Flags) AddTo(cmds ...*cobra.Command) type IFlag type Int func (f *Int) AddTo(cmds ...*cobra.Command) func (f *Int) Get(cmd *cobra.Command, nonnull bool) *int type String func (f *String) AddTo(cmds ...*cobra.Command) func (f *String) Get(cmd *cobra.Command, nonnull bool) *string type StringSlice func (f *StringSlice) AddTo(cmds ...*cobra.Command) func (f *StringSlice) Get(cmd *cobra.Command, nonnull bool) *[]string Constants ¶ This section is empty. Variables ¶ This section is empty. Functions ¶ This section is empty. Types ¶ type Bool ¶ added in v0.0.3 type Bool struct { *Flag Default bool // contains filtered or unexported fields } func (*Bool) AddTo ¶ added in v0.0.3 func (f *Bool) AddTo(cmds ...*cobra.Command) func (*Bool) Get ¶ added in v0.0.3 func (f *Bool) Get(cmd *cobra.Command, nonnull bool) *bool type Flag ¶ type Flag struct { Name string ShortName string Description string Required bool } func (*Flag) Changed ¶ func (f *Flag) Changed(cmd *cobra.Command) bool type Flags ¶ type Flags []IFlag func (Flags) AddTo ¶ func (fs Flags) AddTo(cmds ...*cobra.Command) type IFlag ¶ type IFlag interface { AddTo(cmds ...*cobra.Command) } type Int ¶ type Int struct { *Flag Default int // contains filtered or unexported fields } func (*Int) AddTo ¶ func (f *Int) AddTo(cmds ...*cobra.Command) func (*Int) Get ¶ func (f *Int) Get(cmd *cobra.Command, nonnull bool) *int type String ¶ type String struct { *Flag Default string // contains filtered or unexported fields } func (*String) AddTo ¶ func (f *String) AddTo(cmds ...*cobra.Command) func (*String) Get ¶ func (f *String) Get(cmd *cobra.Command, nonnull bool) *string type StringSlice ¶ type StringSlice struct { *Flag Default []string // contains filtered or unexported fields } func (*StringSlice) AddTo ¶ func (f *StringSlice) AddTo(cmds ...*cobra.Command) func (*StringSlice) Get ¶ func (f *StringSlice) Get(cmd *cobra.Command, nonnull bool) *[]string Source Files ¶ View all Source files flags.go Click to show internal directories. Click to hide internal directories.