[PATCH v11 08/21] argparse: support parameters to short options without "="

fengchengwen fengchengwen at huawei.com
Wed Oct 15 14:20:46 CEST 2025


Please add document about this,
Acked-by: Chengwen Feng<fengchengwen at huawei.com>

On 2025/10/9 21:00, Bruce Richardson wrote:
> When passing an optional parameter to a argparse argument, the only way
> to do so has been to pass the argument using "=arg" on the end of the
> option, for example "--foo=bar". However, for short options, i.e. those
> of the form "-x", this requirement is unusual as getopt also supports
> taking additional characters after the option as the parameter, e.g.
> "-xarg".
>
> Add support for this form of parameter for short options to argparse.
>
> Signed-off-by: Bruce Richardson<bruce.richardson at intel.com>


More information about the dev mailing list