README ¶ args example <tmpl,code=go:cat args.go> package main import ( "fmt" "github.com/jpillora/opts" ) type Config struct { Bazzes []string `min:"2"` } func main() { c := Config{} opts.New(&c).Parse() for i, foo := range c.Bazzes { fmt.Println(i, foo) } } ``` $ args --foo hello --bar world ``` ``` plain 0 foo 1 bar ``` ``` $ args --help ``` ``` plain Usage: args [options] bazzes... Options: --help, -h </tmpl> Expand ▾ Collapse ▴ Documentation ¶ There is no documentation for this package. Source Files ¶ View all Source files args.go Click to show internal directories. Click to hide internal directories.