options

package
v0.0.4 Latest Latest
Warning

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

Go to latest
Published: Jan 1, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BindConfig

func BindConfig(v *viper.Viper, cmd *cobra.Command) error

BindConfig binds the config file to cobra flags

Types

type ConvertOptions

type ConvertOptions struct {
	Format     string
	Encoding   string
	OutputPath string
}

ConvertOptions defines the options for the `convert` command

func (*ConvertOptions) AddFlags

func (o *ConvertOptions) AddFlags(cmd *cobra.Command)

AddFlags adds command line flags for the ConvertOptions struct

type Interface

type Interface interface {
	// AddFlags adds this options' flags to the cobra command.
	AddFlags(cmd *cobra.Command)
}

type RootOptions

type RootOptions struct {
	ConfigPath string
	Verbose    int
}

RootOptions defines the options for the `root` command

func (*RootOptions) AddFlags

func (ro *RootOptions) AddFlags(cmd *cobra.Command)

AddFlags adds command line flags for the RootOptions struct

Jump to

Keyboard shortcuts

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