Hi, I noticed that missing a required arg in a subcommand does not return an error when parsed. E.g.:
type GenerateCmd struct {
name string `arg:"required"`
}
var mainCmd struct {
Generate *GenerateCmd `arg:"subcommand:generate"`
}
p, err := NewParser(Config{}, &mainCmd)
// no error here.
if err := p.Parse([]string{"generate"}); err != nil {
// Should have error, but doesn't.
}
Is this intended? Is it because it's not a positional arg? I'm using v1.4.3.
Hi, I noticed that missing a required arg in a subcommand does not return an error when parsed. E.g.:
Is this intended? Is it because it's not a positional arg? I'm using v1.4.3.