Documentation
¶
Index ¶
- func Bool(name string, value bool, usage string, envKey string) *bool
- func DumpAll(ctx context.Context)
- func Float64(name string, value float64, usage string, envKey string) *float64
- func Int(name string, value int, usage string, envKey string) *int
- func Parse() error
- func Parsed() bool
- func PrintDefaults()
- func Reset()
- func String(name string, value string, usage string, envKey string) *string
- type FlagParser
- type FlagValueDumper
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Bool ¶
Bool is a similar to flag.Bool but it also parse value from specified environment variable when the parameter was not provided explicitly on command line argument. Environment variables are ignored when the given envKey is an empty string.
func Float64 ¶ added in v0.58.2
Float64 is similar to flag.Float64 but it also parses value from specified environment variable when the parameter was not provided explicitly on command line argument. Environment variables are ignored when the given envKey is an empty string.
func Int ¶
Int is a similar to flag.Int but it also parse value from specified environment variable when the parameter was not provided explicitly on command line argument. Environment variables are ignored when the given envKey is an empty string.
func PrintDefaults ¶
func PrintDefaults()
Types ¶
type FlagParser ¶
type FlagParser func() error
type FlagValueDumper ¶
type FlagValueDumper func() string