by ben0x539 · 1y ago · 0 comments
(Python's docopt is also amazing, fwiw)
It has quirks once you try to do something more complex/advanced, but for most of the simple stuff it's very nice to use.
There's also `typer` from the creator of `fastapi` which relies on type annotations. I have not had the opportunity to use it.
https://docs.pydantic.dev/latest/concepts/pydantic_settings/...
https://gist.github.com/porridgewithraisins/313a26ee3b827f73...
I love the ergonomics of this method, and I was going to improve it to support subcommands, etc, but now I think I will use the library you posted.
There's implementations for other languages, too.
TIL about structopt, thanks.