Commit 9a454c8e4e2b1356f356627bad6e3b932efd23c3
Committed by
GitHub
1 parent
794c9752
Improve help of short-only options (remove dangling comma) (#235)
Showing
2 changed files
with
6 additions
and
1 deletions
include/cxxopts.hpp
src/example.cpp
| ... | ... | @@ -49,6 +49,7 @@ parse(int argc, char* argv[]) |
| 49 | 49 | ("i,input", "Input", cxxopts::value<std::string>()) |
| 50 | 50 | ("o,output", "Output file", cxxopts::value<std::string>() |
| 51 | 51 | ->default_value("a.out")->implicit_value("b.def"), "BIN") |
| 52 | + ("x", "A short-only option", cxxopts::value<std::string>()) | |
| 52 | 53 | ("positional", |
| 53 | 54 | "Positional arguments: these are the arguments that are entered " |
| 54 | 55 | "without an option", cxxopts::value<std::vector<std::string>>()) | ... | ... |