1
0
mirror of https://github.com/CLIUtils/CLI11.git synced 2025-04-30 12:43:52 +00:00

48 Commits

Author SHA1 Message Date
Philip Top
ecdcf633a5
Help priority adjustment (#1106)
Move the help generation priority higher so it triggers before config
file processing.

Fixes #1099

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-12-26 06:13:36 -08:00
Josh Soref
ef50bb35c3
Spelling (#1101)
This PR corrects misspellings identified by the [check-spelling
action](https://github.com/marketplace/actions/check-spelling) (which is
an evolution of the script I used ages ago when I first made a PR
here...).

The misspellings have been reported at
https://github.com/jsoref/CLI11/actions/runs/12194174338#summary-34017587518

The action reports that the changes in this PR would make it happy:
https://github.com/jsoref/CLI11/actions/runs/12194174680#summary-34017588281

---------

Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-12-22 14:03:24 -08:00
Philip Top
3539bd185f
Issue 1086 (#1087)
Fixes issue #1086.

In the default_val enums of uint8_t would read in as a string as they
could be converted to a string. This worked ok for normal values, but
when a check was added for specific strings, it caused an error when the
default_val was added. This PR fixes the issue.

The builder for coverage was updated to CMake 3.31 (by github), this
triggered an error in the coverage tool script. This led to updating
that script, which led to uncovering some missing coverage, which led to
additional tests, which led to some issues around single element tuples
support from #1081, which led to a few other issues that came up in the
to_string operation and templates.

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-11-18 05:40:37 -08:00
Henry Schreiner
bd6462f62f
chore: move single file to own folder (#1030)
See https://github.com/CLIUtils/CLI11/pull/1025.

---------

Signed-off-by: Henry Schreiner <henryschreineriii@gmail.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2024-05-01 12:02:16 -04:00
Jose Luis Rivero
852fc94f30
Restore non-arch dependant path for the pkgconfig file (#1012)
Originally setup at https://github.com/CLIUtils/CLI11/pull/635 but
reverted in https://github.com/CLIUtils/CLI11/pull/916 without any
specific reason that I can find.
2024-03-11 08:35:35 -07:00
Philip Top
9dfeefe2ba
update copyright date to 2024 (#971)
update copyright dates
2024-01-06 08:08:31 -08:00
Philip Top
c99918ea5a
add additional tests for coverage, (#928)
Add some additional tests to try to get test coverage back to 100%

 refactor the positional parsing to  reduce code duplication

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2023-10-06 08:38:47 -07:00
Philip Top
c071cb6297
fix: CMake package and pkgconfig rework (#916)
add tests that exercise the CMake module and pkg-config files

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2023-09-15 16:21:15 -04:00
Philip Top
faea921e40
chore: cmake reorganization (#768)
update conan and azure-pipelines to fix gcc 4.8 issue

make the CLI11 target sources only for newer CMake

Change the cmake to use subdirectory and move the library generation and warnings to separate files.
2022-08-25 08:14:59 -04:00
Jose Luis Rivero
d17016e76c
fix(build): relocate cmake and pkgconfig files to an arch-independent path (#635)
* Relocate cmake and pkgconfig files to an arch-independent path

Use CMAKE_INSTALL_DATADIR instead of CMAKE_INSTALL_LIBDIR for
installing the pkgconfig and cmake files.

Signed-off-by: Jose Luis Rivero <jrivero@osrfoundation.org>

* style: pre-commit.ci fixes

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2021-08-22 23:51:30 -04:00
Henry Schreiner
911ee02f6c style: run pre-commit 2021-06-15 14:52:40 -04:00
Henry Schreiner
5d12e11d8a tests: use catch2 2021-04-04 00:29:21 -04:00
djerius
e50a75f231
feat: create pkg-config file (#523) 2020-10-28 12:06:05 -04:00
Isabella Muerte
60e2932356 CMake updates from @slurps-mad-rips 2020-01-09 09:53:58 -05:00
Philip Top
fc0f82a81f Deprecated retired options (#358)
* add ability to specify deprecated or retired options.

* add retired example and tests

* update some formatting and a few more test executions

* fix formatting on retired.cpp

* add another test to fill coverage gap for existing options that are being retired.

* add example comments

* Update readme with the descriptions of the new helper functions

* fix space on readme

* Apply suggestions from code review

Co-Authored-By: Christoph Bachhuber <cbachhuber89@gmail.com>

* add some flags to the code coverage report and update some names and add more descriptions to deprecated options

* update formatting on App
2019-12-04 21:16:30 -05:00
Henry Fredrick Schreiner
fda6126d7c Adding pre-commit 2019-10-24 19:07:01 -04:00
Henry Schreiner
e6aca64d6f
Upgrade googletest, drop GCC 4.7 (#160) 2019-07-25 11:09:17 -04:00
Henry Schreiner
7b315782e1
Warnings (#281)
* Fixing some warnings

* Make gtest a system library

* Fixing format

* Adding better method for adding warnings

* Nicer Windows deprecated test

* JSON update and drop testing timer

* Warnings as errors everywhere
2019-05-18 19:11:27 +02:00
Paul le Roux
80420d62e2 Make ConfigVersion arch independent (#254)
CLI11 is header only and the architecture shouldn't matter. The arch
dependence has the potential to cause find_package to fail incorrectly.
2019-03-22 17:57:46 -04:00
Philip Top
49e93cac3c add docs for remove_subcommand and add_subcommand in option_group
add some test of the remove_excludes functions

add test for Issue #256

add remove_subcommand fail test

add remove_subcommand function and add_subcommand to option_group and some tests associated with them.
2019-03-22 17:56:36 -04:00
Philip Top
7cd04e3b65 Fixes some cmake issues when using earlier cmake versions specifically Boost::boost is not defined before boost 3.5.2 so 3.4 doesn't work. also the AND condition for MSVC didn't work on older cmake 2019-01-31 19:05:55 +01:00
Henry Fredrick Schreiner
89975e51e7 Updating coverage 2018-04-30 08:17:31 -04:00
Henry Schreiner
a061275eba
Moving to submodules, adding sanitizer (#111) 2018-04-25 18:57:21 -04:00
Henry Fredrick Schreiner
5d9a5636bc Removing enum conversion 2018-04-07 06:58:21 +02:00
Henry Fredrick Schreiner
27cb792c52 Small cleanup to AddGoogleTest 2018-04-05 13:09:00 +02:00
Henry Fredrick Schreiner
0c3df9150c Adding FetchContent on CMake 3.11 2018-04-04 20:31:52 +02:00
Henry Fredrick Schreiner
20b7232c47 Fix for Windows MSVC 2017 and GoogleTest 2018-04-04 18:29:32 +02:00
Henry Schreiner
79a1847605
Overflow (#84)
* Overflowing an integer conversion now results in a conversion failure

* CMake improvements for VERSION and inital packing support

* Fix for recent addition of overflow check

* Conan file now gets version from Version.hpp file too
2018-03-10 09:50:25 +01:00
Henry Schreiner
f089255ad0
Adding support for conan.io (#83)
* Adding fix for #75, rename requires to needs

* Removing check for install commands (should still be run in subproject)

* Adding conan build

* Some small changes to CMake

* Adding nicer Travis code

* Adding package test, find works now
2018-03-09 08:30:22 +01:00
Henry Fredrick Schreiner
20f881f692 Adding better error messages, Xcode folders 2017-11-22 09:12:09 -05:00
Henry Fredrick Schreiner
6feb10fbc2 Only split up discovery if CMake version is new enough 2017-11-21 21:28:32 -05:00
Henry Fredrick Schreiner
7472295d95 Adding filename to name 2017-11-21 21:28:32 -05:00
Henry Fredrick Schreiner
8e87df2a6c Adding GTest improvments 2017-11-21 21:28:32 -05:00
Henry Schreiner
657b599b52 Cmake cleanup (#21)
* Fixes for #8, vars hidden and findPython used

* Adding compat with default python, better defaults
2017-06-05 11:22:09 -04:00
Henry Fredrick Schreiner
774bb5d05f Cleaner IDE folder structure 2017-06-02 09:03:38 -04:00
Henry Schreiner
89ed072f39 Codecov (#5)
* Adding first try at coverage

* Fix for CMakeLists

* Fix for wrong shell

* Fixes to Coverage

* Fix for missing coverage

* Adding badge

* Using repo token

* Adding test files to coverage

* Fix typo

* Adding codecov

* Fix for code coverage

* Fix single file tests under CodeCov

* Seperating coverage steps

* Fix testrunner to be ctest

* Fix constant rebuilding of doxygen

* Adding coverage, tested locally

* Adding compiler version to gcov

* Fixing code coverage gcov download and use

* Adding Coverage build type with some fixes

* Better way of using gcc

* Adding coverage badge

* Removing tests from calcs
2017-03-07 16:17:30 -05:00
Henry Schreiner
27d120e7b8 Cleaner import 2017-03-07 13:32:39 -05:00
Henry Fredrick Schreiner
d108d65b82 Fixing linker errors using example 2017-02-19 16:09:21 -05:00
Henry Fredrick Schreiner
cef1517fb4 Fixing googletest include dirs 2017-02-19 15:58:46 -05:00
Henry Fredrick Schreiner
1d08a29e40 Adding include dirs 2017-02-19 15:54:31 -05:00
Henry Fredrick Schreiner
b67045a85c Trying google-test-examples for windows style 2017-02-19 15:49:37 -05:00
Henry Fredrick Schreiner
b774c57dc2 Adding help testing, option groups 2017-02-11 09:38:35 -05:00
Henry Fredrick Schreiner
18478d7fb5 Cleaner include of googletest 2017-02-07 15:00:40 -05:00
Henry Fredrick Schreiner
ee5678562f Adding tools to build with python 3.6 directly 2017-02-06 11:51:06 -05:00
Henry Fredrick Schreiner
87155a5def Removing google mock since it is not used here 2017-02-04 15:09:30 -05:00
Henry Fredrick Schreiner
200072dc38 Added update script 2017-02-03 15:43:08 -05:00
Henry Fredrick Schreiner
4b0f6dbfd6 Nicer adding of tests 2017-01-27 10:26:52 -05:00
Henry Fredrick Schreiner
3eac26e2e1 Adding DownloadProject to cmake 2017-01-27 09:40:45 -05:00