-
Notifications
You must be signed in to change notification settings - Fork 107
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Tweaked usage template to resemble other popular CLI tools #523
Conversation
Looks pretty yeah, just means we have to. make sure we keep the descriptions short. If you want to contribute to fisk you can, but we can also try it here if easier |
Ideally we also seperate the command specific flags from the top level noise - but kingpin and therefor fisk doesnt have data to make that possible |
Yeah that was next on my list after this :) |
@ripienaar I think it will be cleaner if this was in fisk. Are you okay with this format affecting choria tooling? Otherwise I can just bake in a couple more hooks in fisk and make most of the changes here |
Add it to fisk but some new name - leaving default as is. We'll opt this project into that new format (perhaps under a feature flag to preview?) |
Cool. Sounds good |
@ripienaar This PR now relies on choria-io/fisk#23, but ended up being a much cleaner implementation. I also was able to separate global and local flags and it feels a lot more ergonomic to me. |
yeah looks great, so update this PR to go get that latest commit on fisk and use that here and we can merge that so we have a few days to test before next release |
@ripienaar Thanks for looking at this today. Should be all upgraded to the latest fisk commit |
very nice, thank you |
This PR is mostly just a proposal to change the usage template to be a bit cleaner, more compact and readable. I took a cue from
gh
,terraform
andkubectl
and decided to go for a 2 column command/subcommand format with flags at the bottom.@ripienaar I think this likely should live in https://github.com/choria-io/fisk and reuse/rework the column formatting funcs in that package. I also would want to change the
compactWithoutFlagsOrArgs
template you recently added to use a similar format to the usage template. WDYT?Let me know and I can move this into a PR on fisk, just wanted to get your thoughts here before I do so.