readme update

This commit is contained in:
Mario Hros 2017-03-08 20:52:02 +01:00
parent 9173d259ef
commit 9e6f80aa90
1 changed files with 10 additions and 10 deletions

View File

@ -37,7 +37,7 @@ arg.MustParse(&args)
```shell ```shell
$ ./example $ ./example
usage: example --id ID [--timeout TIMEOUT] Usage: example --id ID [--timeout TIMEOUT]
error: --id is required error: --id is required
``` ```
@ -108,13 +108,13 @@ arg.MustParse(&args)
```shell ```shell
$ ./example -h $ ./example -h
usage: [--verbose] [--dataset DATASET] [--optimize OPTIMIZE] [--help] INPUT [OUTPUT [OUTPUT ...]] Usage: [--verbose] [--dataset DATASET] [--optimize OPTIMIZE] [--help] INPUT [OUTPUT [OUTPUT ...]]
positional arguments: Positional arguments:
input INPUT
output OUTPUT
options: Options:
--verbose, -v verbosity level --verbose, -v verbosity level
--dataset DATASET dataset to use --dataset DATASET dataset to use
--optimize OPTIMIZE, -O OPTIMIZE --optimize OPTIMIZE, -O OPTIMIZE
@ -162,7 +162,7 @@ if args.Foo == "" && args.Bar == "" {
```shell ```shell
./example ./example
usage: samples [--foo FOO] [--bar BAR] Usage: samples [--foo FOO] [--bar BAR]
error: you must provide one of --foo and --bar error: you must provide one of --foo and --bar
``` ```
@ -259,7 +259,7 @@ $ ./example --name=foo.bar
&main.NameDotName{Head:"foo", Tail:"bar"} &main.NameDotName{Head:"foo", Tail:"bar"}
$ ./example --name=oops $ ./example --name=oops
usage: example [--name NAME] Usage: example [--name NAME]
error: error processing --name: missing period in "oops" error: error processing --name: missing period in "oops"
``` ```
@ -283,9 +283,9 @@ func main() {
```shell ```shell
$ ./example -h $ ./example -h
this program does this and that this program does this and that
usage: example [--foo FOO] Usage: example [--foo FOO]
options: Options:
--foo FOO --foo FOO
--help, -h display this help and exit --help, -h display this help and exit
``` ```