Commit Graph

367 Commits

Author SHA1 Message Date
Alex Flint f0f44b65d1
Merge pull request #175 from alexflint/bracketing-positionals
Fix bracketing for non-required positionals in usage
2022-02-09 18:04:03 -08:00
Alex Flint 5fb236a65d fix bracketing for non-required positionals 2022-02-09 06:31:34 -08:00
Alex Flint d3706100bf
Merge pull request #173 from GreyXor/master
Update testify dependency to 1.7.0
2022-01-05 10:02:04 -05:00
GreyXor 25d4d1c864
Update go.sum 2022-01-05 15:58:54 +01:00
GreyXor 3bf2a5e78a
Update testify dependency to 1.7.0 2022-01-05 15:43:52 +01:00
Sebastiaan Pasterkamp a87d80089a Add 'IgnoreDefault' option 2022-01-02 15:17:09 +01:00
Alex Flint bf32f08247
Merge pull request #166 from alexflint/env-in-error
Put name of environment variable in error message
2021-10-01 04:44:19 -07:00
Alex Flint b47d6e3da6 put name of environment variable in error message 2021-10-01 04:35:15 -07:00
Alex Flint a4afd6a849
Merge pull request #156 from alexflint/usage-for-subcommands
add FailSubcommand, WriteUsageForSubcommand, WriteHelpForSubcommand
2021-09-18 08:57:29 -07:00
Alex Flint f2f876420c Merge remote-tracking branch 'origin/master' into usage-for-subcommands 2021-09-18 08:55:40 -07:00
Alex Flint 66cb696e79
Merge pull request #164 from evgenv123/evgenv123-patch-1
Update README.md
2021-09-18 08:53:02 -07:00
Alex Flint 0f0b4b5c3f
Update README.md 2021-09-18 08:50:33 -07:00
evgenv123 b157e8d10a
Update README.md
Hi! As a first-time user of your great package I got a little bit confused on using command line args and env vars together, so it took me some time to make testing and I propose to save this time for other people by adding relevant edits to README.md
2021-09-18 22:23:26 +07:00
Alex Flint ff38a63b36
Merge pull request #162 from alexflint/support-for-urls
Add support for URLs
2021-08-20 19:59:18 -07:00
Alex Flint 3d59e5e89e bump go-scalar to v1.1 and add documentation about supported types 2021-08-20 19:52:48 -07:00
Alex Flint eb0393e9bc
Merge pull request #158 from alexflint/unexported-embedded
Recurse into unexported embedded structs
2021-05-24 21:50:33 -07:00
Alex Flint fa12c02e81 recurse into unexported embedded structs 2021-05-24 21:45:11 -07:00
Alex Flint 7cc8da61cf simplify the error string logic 2021-05-09 14:01:08 -07:00
Alex Flint c9b504edc1 add FailSubcommand, WriteUsageForSubcommand, WriteHelpForSubcommand 2021-05-09 13:55:34 -07:00
Alex Flint 679be43af3
Merge pull request #153 from alexflint/test-empty-map
Fix case where an empty environment variable is parsed in a slice or map
2021-04-20 19:11:21 -07:00
Alex Flint 2e81334206 fix case where an environment variable containing an empty string is parsed into a slice or map 2021-04-20 19:09:47 -07:00
Alex Flint 9d937ba6c9
Merge pull request #152 from alexflint/mappings-with-commas
Add an example of mappings with commas
2021-04-20 12:26:56 -07:00
Alex Flint 1e81bb6866 fix the mappings-with-commas example 2021-04-20 12:23:49 -07:00
Alex Flint 4354574615
Merge pull request #151 from alexflint/fix-lint
Fix lint issue in reflect.go
2021-04-20 12:20:36 -07:00
Alex Flint 473453d8c8 fix lint issue 2021-04-20 12:14:14 -07:00
Alex Flint a84487a43a updated the example for mappings with commas 2021-04-19 21:35:09 -07:00
Alex Flint a0937d1b58
Merge pull request #150 from alexflint/push-coverage-up-more
Push test coverage up to 100%
2021-04-19 21:27:53 -07:00
Alex Flint 01a9fab8d7 clean up environment variable tests 2021-04-19 21:22:12 -07:00
Alex Flint fe4a138ac8 test coverage 100% !! 2021-04-19 21:03:43 -07:00
Alex Flint 6a01a15f75
Merge pull request #149 from alexflint/parse-into-map
Add support for parsing into a map
2021-04-19 19:27:31 -07:00
Alex Flint d4b9b2a008 push coverage up even more 2021-04-19 19:23:08 -07:00
Alex Flint a80336128c more test coverage 2021-04-19 14:50:05 -07:00
Alex Flint 57f610284f add an runnable example for mappings 2021-04-19 14:01:29 -07:00
Alex Flint 91214e01ea add an example of parsing into a map to the readme 2021-04-19 13:59:00 -07:00
Alex Flint 0100c0a411 push code coverage up 2021-04-19 13:48:07 -07:00
Alex Flint bb4e7fd4b0 add unittests for maps as environment variables with the separate flag 2021-04-19 13:33:31 -07:00
Alex Flint ccf882dca7 finish adding comments to spec 2021-04-19 13:25:11 -07:00
Alex Flint 9949860eb3 change "kind" to "cardinality", add support for maps to parser 2021-04-19 13:21:04 -07:00
Alex Flint 23b96d7aac refactor canParse into kindOf 2021-04-19 12:49:49 -07:00
Alex Flint 1dfefdc43e factor setSlice into its own file, add setMap, and add tests for both 2021-04-19 12:10:53 -07:00
Alex Flint f4eb7f3a58
Merge pull request #137 from alexflint/optional-long
Optional long names
2021-04-16 21:03:14 -07:00
Alex Flint 113aef7114
Merge pull request #147 from alexflint/ci-go16
Add go 1.16 to CI
2021-04-16 21:01:28 -07:00
Alex Flint cec6b0d378 add go 1.6 to CI 2021-04-16 20:45:13 -07:00
Alex Flint 172800ff9a fix a comment 2021-04-16 20:44:18 -07:00
Alex Flint cf2205c84d
Merge pull request #144 from leozhantw/refactor/remove-unused-function
refactor: remove unused function
2021-04-07 11:32:48 -07:00
LeoZhan 4f2ab5c009 refactor: remove unused function 2021-04-08 00:20:56 +08:00
Alex Flint ec285c8ec4 Merge remote-tracking branch 'origin/master' into optional-long 2021-01-31 19:43:30 -08:00
Alex Flint bd6844a20d
Merge pull request #138 from alexflint/ci-go15
Add go1.15 to CI
2021-01-31 19:43:20 -08:00
Alex Flint efe5cdf4da replace "name" and "typ" by storing the original StructField 2021-01-31 19:40:38 -08:00
Alex Flint b099bc916b fix typo 2021-01-31 19:27:06 -08:00