These are chat archives for kbknapp/clap-rs

22nd
Feb 2018
Sean Leffler
@sdleffler
Feb 22 2018 03:04 UTC
Hey folks! I'm about to start writing a rather large and complex CLI using clap which I'd like to remain nicely maintainable and such. It's going to have on the order of dozens of subcommands, each potentially with their own subcommands and so on, and I'd like to be able to splice out subcommands and compile subcommands in/out depending on compile-time feature flags.
My question is: what representation of the clap interface should I be using? YAML, macro, or the straightforward Rust builder representation?
I was thinking of basically creating a parallel directory structure in my project, cli, with a cli.yml file, and then every YAML file in cli being a subcommand (sometimes with directories of their own, containing subcommands.)
Does anyone have a nice strategy for organizing this sort of thing?
Denis Lisov
@tanriol
Feb 22 2018 09:00 UTC
@sdleffler ...or structopt, possibly. Not sure whether it's usable on your scale.