Open tjk opened 10 years ago
Given the following example.docopt:
example.docopt
Naval Fate. Usage: naval_fate.py ship create <name>... naval_fate.py ship <name> move <x> <y> [--speed=<kn>] naval_fate.py ship shoot <x> <y> naval_fate.py mine (set|remove) <x> <y> [--moored|--drifting] naval_fate.py --help naval_fate.py --version Options: -h --help Show this screen. --version Show version. --speed=<kn> Speed in knots [default: 10]. --moored Moored (anchored) mine. --drifting Drifting mine.
I'd expect --speed to equal 10 if no options are passed, however I see this instead:
--speed
$ ./example.out Commands mine == false move == false create == false remove == false set == false ship == false shoot == false Arguments x == (null) y == (null) Flags --drifting == false --help == false --moored == false --version == false Options --speed == (null)
Given the following
example.docopt
:I'd expect
--speed
to equal 10 if no options are passed, however I see this instead: