kubo/commands
Juan Batiz-Benet f738e899c2 cmd2: simplified main
Attention @maybebtc @mappum

I cleaned up + simplified the main flow. Now, all printing
is contained inside main itself! (:cheer:). I do this with
the help of a cmdInvocation struct that has both
a Parse and Run. The only major clunkiness left is that the
"CallCommand" is still its own function. But *shrug*.

Please test it works as we would expect. i changed much of
the flow, so likely that i missed a complicated edge case.

main roadmap:
- parse the commandline to get a cmdInvocation
- if user requests, help, print it and exit.
- run the command invocation
- output the response
- if anything fails, print error, maybe with help
2014-11-14 03:20:02 -08:00
..
cli cmd2: simplified main 2014-11-14 03:20:02 -08:00
http fix(commands/http/handler) check if found 2014-11-14 03:19:57 -08:00
argument.go commands: Added Argument helper constructors 2014-11-14 03:17:39 -08:00
command_test.go commands: Changed option accessor API (Request#Option now returns an OptionValue) 2014-11-14 03:17:38 -08:00
command.go cmds/helptext: indent + newlines + synopsis 2014-11-14 03:20:00 -08:00
option_test.go tests(commands/option) test the OptionValue methods 2014-11-14 03:19:57 -08:00
option.go fix(commands/optionvalue) use the util.ErrCast() 2014-11-14 03:19:59 -08:00
request.go docs(commands/request) 2014-11-14 03:19:59 -08:00
response_test.go commands: Changed option accessor API (Request#Option now returns an OptionValue) 2014-11-14 03:17:38 -08:00
response.go refactor(commands/optionvalue) use 2014-11-14 03:19:57 -08:00