Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incorrect help message for argparse::nargs_pattern::at_least_one #322

Open
ruanformigoni opened this issue Jan 23, 2024 · 1 comment
Open

Comments

@ruanformigoni
Copy link

Greetings,

I've noticed that when using something like:

      m_parser.add_argument("args")
        .nargs(argparse::nargs_pattern::at_least_one)
        .remaining()
        .required()
        .help("Install an application into the default directory");

It generates the help message:

Usage: args [--help] [--version] args

Positional arguments:
  args           Install an application into the default directory [nargs: 0 or more] [required]

Optional arguments:
  -h, --help     shows help message and exits 
  -v, --version  prints version information and exits 

Shouldn't it say nargs: 1 or more instead of 0?

Thanks!

@wanjiadenghuo111
Copy link

wanjiadenghuo111 commented Jan 23, 2024 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants