Open fred1268 opened 1 year ago
It'd be neat if you could handle nested structs to control for flow e.g.
type Command struct{ Foo struct{ Bar ,-b, mandatory } clap:"foo" Biz struct{ Bar ,-b } clap:"biz" }
,-b, mandatory
clap:"foo"
,-b
clap:"biz"
go run main.go foo -b "because bar is required"
go run main.go biz
That being said there's nothing here that prevents the user from doing that themselves
Oh this would be awesome ! Really like clap
It'd be neat if you could handle nested structs to control for flow e.g.
type Command struct{ Foo struct{ Bar
,-b, mandatory
}clap:"foo"
Biz struct{ Bar,-b
}clap:"biz"
}go run main.go foo -b "because bar is required"
go run main.go biz
That being said there's nothing here that prevents the user from doing that themselves