mirror of
https://github.com/CLIUtils/CLI11.git
synced 2025-05-01 21:23:52 +00:00
Add mention in README and CHANGELOG
This commit is contained in:
parent
4dac11c025
commit
7e5f4dae50
@ -25,6 +25,7 @@
|
||||
* Added `CLI::ArgumentMismatch` [#56](https://github.com/CLIUtils/CLI11/pull/56) and fixed missing failure if one arg expected [#55](https://github.com/CLIUtils/CLI11/issues/55)
|
||||
* Support for minimum unlimited expected arguments [#56](https://github.com/CLIUtils/CLI11/pull/56)
|
||||
* Single internal arg parse function [#56](https://github.com/CLIUtils/CLI11/pull/56)
|
||||
* Allow options to be disabled from INI file [#60](https://github.com/CLIUtils/CLI11/pull/60)
|
||||
|
||||
## Version 1.2
|
||||
|
||||
|
@ -173,6 +173,7 @@ The add commands return a pointer to an internally stored `Option`. If you set t
|
||||
* `->check(CLI::NonexistentPath)`: Requires that the path does not exist.
|
||||
* `->check(CLI::Range(min,max))`: Requires that the option be between min and max (make sure to use floating point if needed). Min defaults to 0.
|
||||
* `->transform(std::string(std::string))`: Converts the input string into the output string, in-place in the parsed options.
|
||||
* `->configurable(false)`: Disable this option from being in an ini configuration file.
|
||||
|
||||
These options return the `Option` pointer, so you can chain them together, and even skip storing the pointer entirely. Check takes any function that has the signature `void(const std::string&)`; it should throw a `ValidationError` when validation fails. The help message will have the name of the parent option prepended. Since `check` and `transform` use the same underlying mechanism, you can chain as many as you want, and they will be executed in order. If you just want to see the unconverted values, use `.results()` to get the `std::vector<std::string>` of results.
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user