Open kernel164 opened 3 years ago
Yes this is do-able but I fear that it would add more complexity than it's worth, and would make it more difficult to understand code that uses this library. Are there really cases when you want to repeat a significant number of inner options at different places within the same program?
Our requirement is similar to this => https://doc.traefik.io/traefik/v2.3/reference/static-configuration/cli/
possibly there could be 3 or 4 levels of inner struct.
we used kingpin => https://github.com/alecthomas/kingpin but we would like to move to go-arg.
Idea is to have go-arg,config(yaml,json.. etc) parse into same struct.
Got it. Seems reasonable, and fun to implement :). I'm about to go into a meditation retreat but will try to find time for this afterwards.
Would you be interested in providing some funding to me in order to implement this feature?
I just do opensource projects like you. I started using go-arg for my new codes. thought of having this feature in my new projects. I can contribute as code though.
OK @kernel164, I'd be happy to review a pull request
Here is the idea...
should become
Don't know whether it is already supported but this nicely fits in for nested structs. It's similar to custom parsing for values but for arg names.