Documentation ¶
Index ¶
- Variables
- func AddFileFlag(cmd *cobra.Command, v *string, usage string, opts ...func(cmd *cobra.Command))
- func AddOutputFlag(cmd *cobra.Command, v *string)
- func AddOutputFlags(cmd *cobra.Command, cfg *OutCfg)
- func EnableMarshalling(t reflect.Type)
- func Fmt(a any)
- func Fmtln(a any)
- func Msg(str string) (int, error)
- func NewJMESPathPrinter(w gfmt.Writer, expr string) gfmt.Writer
- func NewJQPrinter(w gfmt.Writer, expr string) gfmt.Writer
- func NewTemplate(output io.Writer, p string) gfmt.Writer
- func Parse(r io.Reader) any
- func Reset()
- func RootHelpFunc(cmd *cobra.Command, _ []string)
- func SetFormat(opts map[string]any)
- type JMESPathWriter
- type JQWriter
- type OutCfg
- type Printer
- type Tmpl
Constants ¶
This section is empty.
Variables ¶
View Source
var Optional = func(cmd *cobra.Command) {}
View Source
var Output io.Writer = os.Stdout
View Source
var Required = func(name string) func(cmd *cobra.Command) { return func(cmd *cobra.Command) { internal.MustNoErr(cmd.MarkFlagRequired(name)) } }
View Source
var StyleProps []string
View Source
var Version string
Functions ¶
func AddFileFlag ¶
func AddOutputFlag ¶
func AddOutputFlags ¶
func EnableMarshalling ¶
func Parse ¶
Parse attempts to detect the input format e.g., JSON and returns the value, which could be a key-value pairs (map) or a slice thereof.
func RootHelpFunc ¶
Types ¶
type JMESPathWriter ¶
Click to show internal directories.
Click to hide internal directories.