Skip to content

Commit ea6a2e2

Browse files
committed
Make option method public
This includes many changes, some of which are not backwards compatible. - option now takes a list of argNames, which is primarily used for determining how many arguments an option takes (now a fixed number), but is also used in help and error messages. - added a bunch of tests, and fixed bugs that were discovered with their creation, particularly around positionals and default/addValidator Also moved each test to its own class. This seems to play better with IntelliJ: - faster editing and refactoring - can run individual tests
1 parent 5311ab9 commit ea6a2e2

File tree

3 files changed

+1081
-784
lines changed

3 files changed

+1081
-784
lines changed

CHANGELOG.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,20 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
77

88
## [Unreleased]
99

10+
### Added
11+
12+
- `ArgParser.option` is now a public method, so it's possible to create many
13+
new option types that were not previously possible. The existing option types
14+
are all written in terms of `option`, so they can be used to get an idea of
15+
how it works.
16+
1017
### Changed
1118

19+
- The `adding` and `positionalList` methods of `ArgParser` have had their
20+
parameters slightly reordered to be consistent with the other methods. The
21+
name(s) come first, if any, followed by `help`.
22+
23+
1224
- Made Delegate and DelegateProvider into abstract classes with internal
1325
constructors. This makes it much easier for me to separate internal and
1426
public parts of their API. THIS IS AN INCOMPATIBLE CHANGE, however it

0 commit comments

Comments
 (0)