Aayush Anand
6eb0ea7738
added fix for issue #235
2022-11-12 20:24:36 +05:30
Pranav
a8aa3cc999
Merge pull request #231 from BryanFlynt/master
...
No install when used as third party
2022-11-08 09:42:30 -06:00
Pranav
2ed761a201
Merge pull request #233 from SergiusTheBest/is-subcommand-used-overload
...
Add is_subcommand_used overload
2022-11-08 09:41:19 -06:00
Sergey Podobry
8e6a36dd0d
Add is_subcommand_used overload
...
It's useful for removing string literals duplication in a code.
2022-11-08 01:31:45 +02:00
BryanFlynt
d201a3e1df
Update CMakeLists.txt
...
Default ON for ARGPARSE_INSTALL
2022-11-05 15:47:39 -06:00
BryanFlynt
764442f0f4
Update CMakeLists.txt
...
Added ARGPARSE_INSTALL
This allows a separate project using argparse through CMake FetchContent_Declare(...) to install the project without having to also install argparse.
2022-11-05 15:45:17 -06:00
Pranav
6960571156
Merge pull request #229 from marzer/fix-sv-is-container
...
Fix std::string_view being identified as a container
2022-11-05 08:53:04 -05:00
Pranav
9c830b9bac
Merge pull request #230 from skrobinson/fix-tidy-check
...
Fix tidy check
2022-11-04 20:27:32 -05:00
Sean Robinson
784aa7916e
Use C++17 standard with clang-tidy in PR checks
...
Needed for std::string_view.
Signed-off-by: Sean Robinson <sean.robinson@scottsdalecc.edu>
2022-11-04 10:19:11 -07:00
Mark Gillard
04faefeae3
Fix std::string_view being identified as a container
2022-11-04 16:41:29 +02:00
Pranav
ed2953aa3d
Merge pull request #218 from skrobinson/feat-bool-argparser
...
Allow check if ArgumentParser has parsed values
2022-10-11 17:46:05 -05:00
Pranav
f53d8690de
Merge pull request #216 from skrobinson/maint-cleaning
...
Maint cleaning
2022-10-11 17:44:45 -05:00
Pranav
caa3186556
Merge pull request #220 from skrobinson/fix-tidy-missing-header
...
Tell clang-tidy where to find argparse.hpp in PR action
2022-10-11 17:43:47 -05:00
Sean Robinson
3fce18503b
Tell clang-tidy where to find argparse.hpp in PR action
...
Resolves the following error during stage one of clang-tidy-pr-comments:
"error: 'argparse/argparse.hpp' file not found [clang-diagnostic-error]"
Closes #219
Signed-off-by: Sean Robinson <sean.robinson@scottsdalecc.edu>
2022-10-11 10:13:33 -07:00
Sean Robinson
f710bbdacf
Add operator bool for ArgumentParser
...
This allows checking whether user input was processed into the parser
or any attached subparsers.
Closes #212
Signed-off-by: Sean Robinson <sean.robinson@scottsdalecc.edu>
2022-10-10 15:26:42 -07:00
Sean Robinson
0c83c631c5
Update CMake version in README example for FetchContent
...
FetchContent_MakeAvailable was added in CMake v3.14. Also includes
end-of-line whitespace clean-ups.
Signed-off-by: Sean Robinson <sean.robinson@scottsdalecc.edu>
2022-10-06 13:57:34 -07:00
Sean Robinson
7af2342d94
Remove link library from add_sample function
...
Resolves the following build error:
CMake Error at CMakeLists.txt:26 (ADD_EXECUTABLE):
Target "ARGPARSE_SAMPLE_custom_assignment_characters" links to target
"argparse::argparse" but the target was not found. Perhaps a
find_package() call is missing for an IMPORTED target, or an
ALIAS target is missing?
Signed-off-by: Sean Robinson <sean.robinson@scottsdalecc.edu>
2022-10-06 13:57:25 -07:00
Pranav
537f5e0d3c
Merge pull request #215 from skrobinson/feat-pr-tidy
...
Add clang-tidy analysis of pull requests
2022-10-06 11:48:44 -05:00
Sean Robinson
f1d75bbb32
Remove unneeded explicit Compare function from map declarations
...
std::less<Key> is the standard's default comparison function, we do not
need to re-declare the same function.
Signed-off-by: Sean Robinson <sean.robinson@scottsdalecc.edu>
2022-10-06 09:18:47 -07:00
Sean Robinson
99057b09a1
Add clang-tidy analysis of pull requests
...
This action runs clang-tidy with results saved to a file which is then
parsed in stage two to post code comments. This multistage process lets
us post PR comments on code from forks.
Signed-off-by: Sean Robinson <sean.robinson@scottsdalecc.edu>
2022-10-05 15:22:44 -07:00
Pranav
e9ae471ea4
Merge pull request #209 from skrobinson/fix-issue-208
...
Fix issue 208
2022-09-23 12:57:02 -05:00
Pranav
168bc9d189
Merge pull request #210 from skrobinson/feat-add-sample-licenses
...
Add an explicit MIT license to each sample source file
2022-09-23 12:56:10 -05:00
Sean Robinson
74b95bc11a
Add an explicit MIT license to each sample source file
...
Signed-off-by: Sean Robinson <sean.robinson@scottsdalecc.edu>
2022-09-23 08:10:06 -07:00
Sean Robinson
50e3afd81d
Replace vector::operator[] use with vector::front
...
This is mostly a style change to match other parts of the code.
Signed-off-by: Sean Robinson <sean.robinson@scottsdalecc.edu>
2022-09-23 08:05:33 -07:00
Sean Robinson
2a15178bb7
Include canonical argument name in nargs range validation error
...
The name of a positional argument is never used.
Closes #208
Signed-off-by: Sean Robinson <sean.robinson@scottsdalecc.edu>
2022-09-23 07:54:58 -07:00
Pranav Srinivas Kumar
997da92556
Bumped version to v2.9
2022-09-21 19:24:04 -07:00
Pranav
d6c3f3b704
Updated cmake command for building samples
2022-09-21 21:17:24 -05:00
Pranav
ce0b491571
Merge pull request #206 from p-ranav/feature/metavar_help_and_usage
...
METAVAR, Improved help, Samples (Based on #187 )
2022-09-21 21:16:37 -05:00
Pranav Srinivas Kumar
b1c7483cf5
Added additional samples and fixed parse_known_args API
2022-09-21 19:08:06 -07:00
Pranav Srinivas Kumar
6f1e89885e
Added nargs to help output, added test samples
2022-09-21 18:48:11 -07:00
Pranav Srinivas Kumar
05232b7487
Started adding samples
2022-09-21 18:09:25 -07:00
Pranav Srinivas Kumar
3b9df0b1e7
Added support for metavar and improved help/usage based on #187
2022-09-21 18:01:36 -07:00
Pranav
5a83edd3c4
Added build and test instructions
2022-09-21 13:10:14 -05:00
Pranav
176b7e7961
Merge pull request #205 from p-ranav/feature/prefix_chars
...
Closes #67 : option-value syntax support
2022-09-21 13:03:36 -05:00
Pranav Srinivas Kumar
d56515f6df
Removed static from lambda function, updated copy constructor for m_assign_chars
2022-09-21 10:58:25 -07:00
Pranav Srinivas Kumar
632ca2fcf8
Added prefix_chars and assign_chars to README #67
2022-09-21 09:53:30 -07:00
Pranav Srinivas Kumar
66730967aa
Added support for custom prefix characters #67
2022-09-21 09:48:48 -07:00
Pranav
2335da9478
Merge pull request #204 from p-ranav/bugfix/warnings
...
Added -Wshadow and -Wconversion to CXX_FLAGS and fixed warnings (related to #159 )
2022-09-21 09:48:25 -05:00
Pranav Srinivas Kumar
616062e2bf
Added -Wshadow and -Wconversion to CXX_FLAGS and fixed warnings
2022-09-21 07:43:46 -07:00
Pranav
1ebaccc350
Merge pull request #203 from p-ranav/feature/option_equals_value
...
Allow --option=value form of arguments (Refactored #185 )
2022-09-21 09:32:05 -05:00
Pranav Srinivas Kumar
b2d2a58510
Removed test file
2022-09-21 07:25:18 -07:00
Pranav
8c91f1a290
Added option=value
example to table of contents
2022-09-21 09:24:17 -05:00
Pranav Srinivas Kumar
6dd2a3cf4b
Added example to README for option=value support
2022-09-21 07:23:02 -07:00
Pranav Srinivas Kumar
20095a697a
Added option=value support using #185
2022-09-21 06:54:34 -07:00
Pranav
d512563c45
Merge pull request #202 from p-ranav/bugfix/94_implicit_conversions
...
Closes #94
2022-09-21 08:29:14 -05:00
Pranav Srinivas Kumar
14287af007
Closes #94
2022-09-21 06:23:42 -07:00
Pranav
4dbc910a49
Merge pull request #201 from p-ranav/feature/parse_known_args
...
parse_known_args
2022-09-21 07:59:12 -05:00
Pranav Srinivas Kumar
6a3c6e06e6
Added 'Parse Known Args' section
2022-09-21 05:54:21 -07:00
Pranav Srinivas Kumar
6e23d5b22e
Closes #181
2022-09-21 05:47:47 -07:00
Pranav Srinivas Kumar
4f10f378c5
Bumped version to v2.8
2022-09-20 21:21:06 -07:00