1
0
mirror of https://github.com/CLIUtils/CLI11.git synced 2025-04-29 20:23:55 +00:00

9 Commits

Author SHA1 Message Date
Philip Top
06ab2d0fbd Footer callback (#309)
fix incorrect parenthesis

update some clang-tidy fixes mainly else after return but a few conversions from into to bool

add extra newline before footer

add an extra field to the extra Error

add a footer callback for help operations
2019-08-18 19:51:14 -04:00
Philip Top
0631189b4d Option groups (#227)
* change the move function to _move_option and add an additional test

add a validation check on min options to make sure it is even possible to succeed.

add some additional tests to cover code paths and potential errors.

add a number of additional tests and checks and fix some issues with the add function in option_groups

clean up example and help formatting

add option_groups example to play with

move create_option_group to a member function using a dummy template

add some optionGroup tests

add min and max options calls and an associated Error call

* add ranges example,  add excludes to app for options and subcommands.

* add some tests on ranges, and some subcommand tests with exclusion

* add tests in optionGroups for some invalid inputs

* add required option to subcommands and option_groups

* add disabled flag

* add disable option to subcommands and some more tests

* start work on ReadMe modifications

* update the readme with descriptions of function and methods added for option_groups

* clear up gcc 4.7 warnings

* some update to the Readme and a few more warnings fixed

* Minor readme touchup
2019-03-01 17:43:08 +01:00
Philip Top
c8bd97156b click-style boolean flags (#219)
Updates to the readme

update the readme with some documentation

add a few more tests to complete code coverage

update with count strings in flags instead an array of strings for each count

add the '!' shortcut notation.  add some checks on the help output

allow the false flag syntax to support --option{false}

add a bool lexical cast to make everything consistent when converting to a bool.  Moved a few functions around

make the command line behave like the INI file wrt flags, flag options are allowed to process the value so `--flag=false` actually does the expected thing.

Add functionality similar to click style argument that allow specifying a false flag that when used generates a false result on the flag.
2019-02-09 23:51:38 +01:00
Philip Top
598046c397 Add unnamed subcommand (#216)
increment the parse_ variable on unnamed subcommands. 

update the readme, and add a formatter test for nameless subcommands in nondefault group with other named subcommands.

add a test of default arguments

add a formatter test

add tests for unnamed subcommands and an example of the partitioned subcommands.

change the app_p to be a shared_ptr so you can add an App later on and merge them together

add the ability to add unnamed subcommands that allow partitioning on options into multiple apps.
2019-02-06 10:27:06 +01:00
Henry Fredrick Schreiner
d46c2c5727 Adding Config class 2018-05-09 16:08:32 +02:00
Henry Fredrick Schreiner
0d9a33d4ca Adding access to current formatter, using shared pointer to link all formatters 2018-05-09 16:08:32 +02:00
Henry Fredrick Schreiner
101d847c29 Use filter fn to simplify, sort includes 2018-05-06 18:36:33 +02:00
Henry Fredrick Schreiner
af2ed66d6e Just use Formatter
Removing OptionFormatter

Rename files

Rename to just Formatter

Remove OptionFormatMode (just needs a bool)

Renaming option functions on formatter
2018-04-30 08:17:31 -04:00
Henry Fredrick Schreiner
952f2913e3 First attempt at formatter (app and option)
in progress: formatters

Getting closer

Working on apps

One test actually runs

All builds, added filter functions

Reverting a few behavours as needed

Repairs

All tests pass

Fixing error with adding help flag

Labels are simpler mappings, normalized setters

Adding help_all

Adding a few more tests

One more line tested

Adding one more check

Adding to readme

Simplify naming

Adding default constructors

Fixing spacing issues with subcommand all printout

Adding a couple of tests
2018-04-30 08:17:31 -04:00