aboutsummaryrefslogtreecommitdiff
path: root/args.hxx
diff options
context:
space:
mode:
Diffstat (limited to 'args.hxx')
-rw-r--r--args.hxx4
1 files changed, 3 insertions, 1 deletions
diff --git a/args.hxx b/args.hxx
index 21dd433..6ec4ab0 100644
--- a/args.hxx
+++ b/args.hxx
@@ -1261,7 +1261,7 @@ namespace args
std::string proglinePostfix;
std::function<void(Subparser&)> parserCoroutine;
- bool commandIsRequired = false;
+ bool commandIsRequired = true;
Command *selectedCommand = nullptr;
mutable std::vector<std::tuple<std::string, std::string, unsigned>> subparserDescription;
@@ -1375,6 +1375,8 @@ namespace args
{ return help; }
/** If value is true, parser will fail if no command was parsed.
+ *
+ * Default: true.
*/
void RequireCommand(bool value)
{ commandIsRequired = value; }