Commit Graph

15 Commits

Author SHA1 Message Date
Mario Hros 992acaf408 tests 2017-03-30 20:47:59 +02:00
Mario Hros 9173d259ef nicer usage output 2017-03-08 20:44:01 +01:00
Emmanouil "Manolis" Maragkakis db27431153 add support for description string 2017-01-23 20:41:12 -05:00
Alex Flint c453aa1a28 add support for version string 2016-09-08 21:18:19 -07:00
Fredrik Wallgren e71d6514f4
Print defaults for multiples
Check if the default value supplied is a slice and not nil, if so
print the list of values supplied.
Test case for slice argument with and without default values.
Default values for slices was not printed because slice is not
comparable, but the zero value for slices is nil.
2016-03-06 21:07:01 +01:00
Alex Flint aaae1550b7 Merge pull request #32 from alexflint/override_program_name
make it possible to override the name of the program
2016-02-22 06:39:41 -08:00
brettlangdon 8dd29d34bf Add support for environment variables 2016-01-18 13:42:04 -05:00
Alex Flint b1ec8c9093 make it possible to override the name of the program 2016-01-18 10:31:01 -08:00
Alex Flint 77be03b907 resolve merge 2016-01-18 08:19:10 -08:00
Alex Rakoczy e4e9e19427 Fix error when printing usage for multi-value arguments
We try to compare []strings, which are uncomparable types:

`panic: runtime error: comparing uncomparable type []string`
2015-12-04 09:59:13 -05:00
brettlangdon d45bd4523c Display help text for positional arguments 2015-11-21 18:59:40 -05:00
Fredrik Wallgren b0d37d1fb2 Add default values to usage
Check if the value isn't it's zero value and if not add a default value
to the usage text.
2015-11-22 00:53:29 +01:00
Fredrik Wallgren 330a0da571
Add built ins to options in help output
Adds help to the options in help output with an easy way to add more
built ins.
2015-11-16 13:23:58 +01:00
brettlangdon 383b8b84c1 Remove excess trailing whitespace from Usage generation 2015-11-07 09:39:23 -05:00
Alex Flint 9111061915 add tests for usage info 2015-11-04 09:47:58 -08:00