Dan Buch
3d75e9e711
Go with interfaces + private opaque types
...
rather than public types that wrap slices
8 years ago
Dan Buch
cd10b49473
Minimize struct copying
...
by using pointer func receivers and slices of struct pointers where possible.
8 years ago
Dan Buch
81fcf706ea
Replace all "stringly typed" fields with slice equivalents
...
and alter the Flag interface accordingly
Closes #415
8 years ago
Dan Buch
c19dbaf230
Remove deprecated things and supporting code
8 years ago
Dan Buch
6f3bb94eae
Correct assertion text
8 years ago
Dan Buch
b9d96954ca
Fix command alias printing in help text
...
Closes #405
8 years ago
Matt Farina
2f4ec31264
Fixed spelling and gofmt issues
8 years ago
Dan Buch
5a5fa990e1
Merge remote-tracking branch 'origin/master' into exit-nonzero-for-unknown-subcommand
8 years ago
Jesse Szwedko
592f1d97e5
Exit non-zero if a unknown subcommand is given
...
Currently it just prints the help message and exits 0.
We do this by modifying the helpCommand and helpSubcommand cli.Commands
to return an error if they are called with an unknown subcommand. This
propogates up to the app which exits with 3 and prints the error.
Thanks to @danslimmon for the initial approach!
Fixes #276
8 years ago
Dan Buch
cc481d6b0e
Adjust command hiding to use similar convention as hidden flags
...
plus breaking out "setup" portion of `App.Run` into its own method, cleaning up
some bits of the help templates, and allowing for runtime opt-in of displaying
template errors to stderr.
9 years ago
Dan Buch
f397b1618c
Adding test for Command.Hidden handling in help text
9 years ago
Dan Buch
b7329f4968
Switch from multi-return with exit codes to ExitCoder check
9 years ago
Dan Buch
10c8309d84
Merge branch 'develop' of https://github.com/txgruppi/cli into txgruppi-develop
9 years ago
Radek Simko
d21170f0e3
Never show version if HideVersion=true
9 years ago
elij
db7af859d2
make help and version parsing use actual specified values
...
fixes #254
9 years ago
Edward Sheffler III
8ea1232ede
Improve vendoring options by removing self-referential imports in tests.
9 years ago
Martin Falatic
dbde3303cf
Test updated
9 years ago
Martin Falatic
595c055010
If Version is an empty string, suppress version output in usage help.
9 years ago
jszwedko
f952f5ac6f
Rename TestShowAppHelp to be more verbose
...
Follow golang convention
10 years ago
jszwedko
96ad929784
Add test for inclusion of 'AUTHORS' in App help
10 years ago