add docs about old way of specifying defaults

This commit is contained in:
Alex Flint 2019-10-21 23:37:12 -07:00
parent 7ac060af18
commit e0fc08f7ad
1 changed files with 11 additions and 0 deletions

View File

@ -148,6 +148,17 @@ var args struct {
arg.MustParse(&args)
```
### Default values (before v1.2)
```go
var args struct {
Foo string
Bar bool
}
arg.Foo = "abc"
arg.MustParse(&args)
```
### Arguments with multiple values
```go
var args struct {