argbash icon indicating copy to clipboard operation
argbash copied to clipboard

ARG_OPTIONAL_BOOLEAN no need to generate the --no-xxx by default

Open Gcaufy opened this issue 3 years ago • 1 comments

Ref: https://github.com/matejak/argbash/issues/14

For example, I have a --yes option.

# ARG_OPTIONAL_BOOLEAN([yes],[y],[Delete action without confirm again])

It generated like this:

The general script's help msg
Usage: /tmp/test.sh [-y|--(no-)yes] [-h|--help]
	-y, --yes, --no-yes: Delete local branches without confirm (off by default)
	-h, --help: Prints help

--no-yes make no sense. and it's totally unnecessary to generate the --no-xxxx option, because the value is off by default.

Gcaufy avatar Apr 26 '21 07:04 Gcaufy

I agree.

matejak avatar Oct 03 '22 22:10 matejak