bw2 / ConfigArgParse

A drop-in replacement for argparse that allows options to also be set via config files and/or environment variables.
MIT License
722 stars 121 forks source link

Add support for args with action append and nargs>1 #200

Closed ianco closed 3 years ago

ianco commented 3 years ago

For args that are setup as:

add_arg('--m', action="append", nargs=3, metavar=("", "", ""),)

(action append and nargs>1)

... parse the input file as an array of arrays:

m = [[1, 2, 3], [4, 5, 6]]

ianco commented 3 years ago

Related to #96 ? This adds support to the default file format not yaml