matejak / argbash

Bash argument parsing code generator
Other
1.39k stars 63 forks source link

function_generators: evaluate_strictness: return 0 if function succeeded #167

Closed nicola-lunghi closed 1 year ago

nicola-lunghi commented 1 year ago

If the [[ a =~ b]] comparison return false, the function returns false as well. This makes the script exit if I set the errexit options if the input are valid

This fixes issue https://github.com/matejak/argbash/issues/163

matejak commented 1 year ago

Could you please extend your PR so it adds the corresponding check to the test suite? AFAIK, your use case corresponds to e.g. setting set -e as in https://github.com/matejak/argbash/blob/master/tests/regressiontests/basic.m4. Would it be possible to extend that script, so it expands that offending code?

Thank you for your PR, and don't be shy to add your name to AUTHORS as well.

nicola-lunghi commented 1 year ago

fixed in https://github.com/matejak/argbash/pull/173