193 Commits

Author SHA1 Message Date
Philip Top
bfffd37e1f code simplification (#1244)
Based on #1242, I don't think this is required but it does remove that
issue and checking on compiler explore it does simplify the generated
code.

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-10-27 06:17:19 -07:00
Philip Top
8ddadd7cea patch release for recent fixes (#1241)
updates for patch release

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-10-25 12:53:47 -07:00
Philip Top
3914826ef8 Version update (#1219)
update changelog for 2.6 release

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-10-20 06:07:51 -07:00
Philip Top
4160d259d9 update version and changelog for 2.5 release (#1121)
update readme, changelog, and version for 2.5 release

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Henry Schreiner <HenrySchreinerIII@gmail.com>
2025-02-27 04:25:31 -08:00
Philip Top
b038a403ca Issue cleanup (#1059)
Fix docstring related to #1052 
Fix config_to_string with defaults #1007

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-07-29 05:32:11 -07:00
Philip Top
08d840bfbe Group merge (#1039)
This PR adds a mechanism to hide groups but have their options visible
as part of the parent.
This works for option group names starting with a '+'

for example 
```
 CLI::App app;

    bool flag = false;
    std::optional<bool> optional_flag = std::nullopt;

    app.add_option("--tester");
    auto *m1=app.add_option_group("+tester");

    m1->add_option("--flag", flag, "description");
    m1->add_option("--optional_flag", optional_flag, "description");

    CLI11_PARSE(app,argc, argv);
```
will produce help as 
```txt
Options:
  -h,--help                   Print this help message and exit
  --tester
  --flag BOOLEAN              description
  --optional_flag BOOLEAN     description
```

instead of 
```
Options:
  -h,--help                   Print this help message and exit
  --tester
[Option Group: tester]
  Options:
    --flag BOOLEAN              description
    --optional_flag BOOLEAN     description

```

Fixes issue #1034 and a few other past issues or questions

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-05-20 11:14:55 -07:00
Henry Schreiner
acf4263d89 docs: missing link
Signed-off-by: Henry Schreiner <henryschreineriii@gmail.com>
2024-05-04 00:57:11 -04:00
Henry Schreiner
6c7b07a878 chore: prepare version 2.4.2 (#1037)
Prepare for release.

---------

Signed-off-by: Henry Schreiner <henryschreineriii@gmail.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Philip Top <phlptp@gmail.com>
2024-05-04 00:50:51 -04:00
Henry Schreiner
f4d0731ceb chore: prepare for 2.4.1 (#1001)
Quick release fixing the missing header.

---------

Signed-off-by: Henry Schreiner <henryschreineriii@gmail.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Philip Top <phlptp@gmail.com>
2024-02-07 19:13:27 -08:00
Philip Top
88e9bb1741 docs: release update (#974)
Update the Readme and the changelog in preparation for a release.

---------

Signed-off-by: Henry Schreiner <henryschreineriii@gmail.com>
Co-authored-by: Henry Schreiner <henry.fredrick.schreiner@cern.ch>
Co-authored-by: Henry Schreiner <henryschreineriii@gmail.com>
2024-02-04 22:59:34 -05:00
Henry Schreiner
291c58789c chore: prepare for 2.3.2 (#824)
* chore: prepare for 2.3.2

Signed-off-by: Henry Schreiner <henryschreineriii@gmail.com>

* chore: bump versions for 2.3.2

Signed-off-by: Henry Schreiner <henryschreineriii@gmail.com>

Signed-off-by: Henry Schreiner <henryschreineriii@gmail.com>
2023-01-03 19:12:23 -05:00
Henry Schreiner
c2ea58c7f9 chore: prepare for 2.3.1 (#797)
Signed-off-by: Henry Schreiner <henryschreineriii@gmail.com>

Signed-off-by: Henry Schreiner <henryschreineriii@gmail.com>
2022-10-31 23:54:32 -04:00
Henry Schreiner
9158ce65bf chore: update changelog (#776)
Signed-off-by: Henry Schreiner <henryschreineriii@gmail.com>

Update CHANGELOG.md
2022-10-05 23:52:52 -04:00
Henry Schreiner
4f14dbde63 style: run pre-commit on linewidth 2022-05-10 13:47:38 -04:00
Henry Schreiner
0038ad4658 style: run prettier 2022-05-10 13:47:38 -04:00
Philip Top
b9be5b9444 docs: update readme and changelog and version number (#718)
* Update readme and changelog and version number

* style: pre-commit.ci fixes

* fix missing references

* style: pre-commit.ci fixes

* merge in changes from non existent 2.1.3 patch release

* Update CHANGELOG.md

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Henry Schreiner <HenrySchreinerIII@gmail.com>
Co-authored-by: Henry Schreiner <henry.fredrick.schreiner@cern.ch>
2022-03-26 23:35:05 -04:00
Philip Top
17e7d60c18 fix: several small fixes and added tests (#666)
* add a few tests related to github issues

* change how the default is displayed in the help message prev was =XXXX,  this was confusing in some cases particularly with flags or with multiple option names.    Now is [default=XXXX]  which makes it clearer what the value represents.

* Try to fix RTTI issue

* style: pre-commit.ci fixes

* Fix subcommand callbacks being called multiple times if in an option group

* style: pre-commit.ci fixes

* remove extra group call

* change [default=XXXXD] to just [XXXXX] for the default specification

* update changelog

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2021-11-21 23:44:04 -05:00
Henry Schreiner
70f8072f9d chore: bump version (#658)
* chore: update changelog for 2.1.2

* chore: bump version
2021-10-18 10:14:21 -04:00
Henry Schreiner
98d200bd8b chore: move to main 2021-10-17 22:39:05 -04:00
Henry Schreiner
a393e353ef fix(build): simplify runs from master projects, require C++11 minimally if possible (#656) 2021-10-16 12:31:24 -04:00
Henry Schreiner
229844f4f8 docs: update CHANGELOG 2021-10-13 15:35:59 -04:00
Henry Schreiner
f19629f84c docs: add recent changes 2021-09-29 07:21:42 -04:00
Henry Schreiner
b440890eaf docs: changelog update (#643)
* docs: changelog update

* chore: bump version(s)

* style: pre-commit.ci fixes

* docs: spelling fix

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2021-09-24 20:37:01 -04:00
Henry Schreiner
ac29910a69 docs: prepare for 2.1 (#638)
* docs: changelog update

* docs: prepare for 2.1

* Apply suggestions from code review

Co-authored-by: Philip Top <top1@llnl.gov>

Co-authored-by: Philip Top <top1@llnl.gov>
2021-09-20 15:50:58 -04:00
Henry Schreiner
2ea663bcc7 style: add remarklint 2021-07-19 15:23:35 -04:00
Henry Schreiner
4698131216 style: add mdlint 2021-07-19 15:23:35 -04:00
Henry Schreiner
b4f6be31c1 chore: codacity (#621)
* docs: fix some Codacity recommendations

* chore: update copyright year

* style: more codacity fixes

* style: fix issues reported by Codacity
2021-07-16 17:41:46 -04:00
Henry Schreiner
9e247b1a0c fix: single header file pragma missing (#620) 2021-07-15 09:59:46 -04:00
Henry Schreiner
975e58b3ed docs: add more notes about releases (#617)
* docs: add more notes about releases

* docs: update badges

* ci: fix file upload
2021-07-14 13:29:10 -04:00
Henry Schreiner
0d06d21b56 docs: fix rendering issue for changelog on GitHub 2021-07-14 11:34:43 -04:00
Henry Schreiner
c9558b3470 chore: changelog update 2021-07-11 20:11:03 -04:00
Henry Schreiner
c4f1fc8ea7 refactor!: remove add_complex (#600) 2021-06-16 20:33:22 -04:00
Henry Schreiner
e2e3cb2fed refactor!: drop defaulted from add_option (#597) 2021-06-16 11:16:22 -04:00
Henry Schreiner
97f5460fbe docs: update changelog (#564) 2021-04-04 01:58:15 -04:00
Henry Schreiner
b270058493 doc: changelog 2020-06-14 11:36:41 -04:00
Henry Schreiner
9f27da026e doc: changelog
[skip ci]
2020-06-14 11:35:04 -04:00
Henry Schreiner
f80a69de3b Update changelog 2020-06-01 23:01:09 -04:00
Josh Soref
51a0efcbbc Spelling (#429)
* spelling: argument

* spelling: conflicts

* spelling: correctly

* spelling: default

* spelling: description

* spelling: empty

* spelling: enum

* spelling: javascript

* spelling: modifying

* spelling: nonexistent

* spelling: plumbum

* spelling: programmatically

* spelling: received

* spelling: replaced

* spelling: required

* spelling: sanitizers

* spelling: semicolon

* spelling: source

* spelling: subcommands

* spelling: successful
2020-02-12 00:41:58 -05:00
Henry Schreiner
dd0d8e4fe7 Bump version to 1.9.0 (#408)
* Bump version to 1.9.0

* Include CMake mention
2020-01-19 17:00:53 -06:00
Henry Schreiner
7a85aa9118 Update CHANGELOG.md 2020-01-06 14:21:25 -05:00
Henry Schreiner
59052a6b27 Update changelog (#383)
* Update changelog

[skip ci]

* Use code for maintainers instead

* Generate file with GitHub Actions

* Apply suggestions from code review

Co-Authored-By: Philip Top <phlptp@gmail.com>

* Adding default val and combine one line

Co-authored-by: Philip Top <top1@llnl.gov>
2020-01-02 17:38:44 -05:00
Henry Fredrick Schreiner
eb6f759f51 Update changelog 2019-07-30 23:07:52 -04:00
Henry Schreiner
e6aca64d6f Upgrade googletest, drop GCC 4.7 (#160) 2019-07-25 11:09:17 -04:00
Henry Fredrick Schreiner
acee69a8cc Update changelog and contributers
[skip ci]
2019-05-18 06:40:10 +02:00
Henry Schreiner
433fd91212 Build testing (#277)
* build-testing better supported

* Add formatting to Azure

* Adding more jobs to Azure

* Control

* Allow libc++ to be used on linux

* Fix modernize message

* Fix variable

* fixup! Fix modernize message

* Drop auto exp. optional

* Update readme, better user id in docker

* Fix BUILD_TESTING

* Drop format from travis, leave tidy for now

* Check tidy and format

* Tidy fully on Azure now
2019-05-14 15:33:15 +02:00
Henry Schreiner
d81843002a To string and default option revamp (#242)
* First streaming version

* Using to_string instead

* Switching to new backend

* Moving to capture function for defaults

* Rename capture_default + _str

* defaultval -> default_str, added always_capture_default

* Fix style

* Adding tests and docs to readme

* Dropping macOS on Travis (supported through Azure)
2019-04-28 22:44:30 +02:00
Henry Fredrick Schreiner
c4fe25b60c Adding some details to changelog 2019-02-28 10:37:17 +01:00
Henry Fredrick Schreiner
1a1cde98f5 Updates to changelog
[skip ci]
2019-02-21 08:59:23 +01:00
Henry Schreiner
5e0bb1c8da Fix Boost CMake (#226)
* Fixing typos in FindBoost

* Minimum required Boost is actually 1.61
2019-02-19 14:08:36 +01:00
Henry Schreiner
c9123811d1 CLI::IsMember (#222)
* Adding first draft of Sets

Use IsMember now

Using IsMember as backend for Set

Non-const validator backend

Move set tests to set

Clearer inits

* Drop shortcut

Tighten up classes a bit for MSVC

Check with GCC 4.8 too

* Simpler templates, but more of them

Dropping more type safety for older compilers

Shortcut string set

* Adding shortcut init

Making g++ 4.7 docker image happy

Fix Clang tidy issue with last commit

Adding one more shortcut, adding a couple of tests

* Dropping dual pointer versions of code

* Smarter shortcut syntax

* Adding slighly faster choices

* Cleanup to make InMember simpler

* Drop choices for now, adding some tests

* ValidationError is now always the error from a validator

* Support for other types of initializer lists, including enums

* Factor out type utilities, single version of IsMember code

* Adding a few tests for #224

* Minor cleanup for Validation Error

* Adding tests, moved deprecated tests

* Docs updates
2019-02-19 09:56:02 +01:00