-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
feat(Completions): one can generate a basic fish completions script at compile time #579
Conversation
Thanks for the pull request, and welcome! The team is excited to review your changes, and you should hear from @sru (or someone else) soon. If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. Due to the way GitHub handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes. Please see the contribution instructions for more information. |
☔ The latest upstream changes (presumably #570) made this pull request unmergeable. Please resolve the merge conflicts. |
🎉 🎉 @wdv4758h Can you rebase onto the latest master? Then we can merge this awesomeness! Thanks! 👍 |
…t compile time The following completion would happen (using example 17_yaml.rs): ``` $ prog <tab> help subcmd ``` ``` $ prog -<tab><tab> --help -h (Prints help information) --max-vals (you can only supply a max of 3 values for me!) --min-vals (you must supply at least two values to satisfy me) --mode (shows an option with specific values) --mult-vals (demos an option which has two named values) --option -o (example option argument from yaml) --version -V (Prints version information) -F (demo flag argument) ``` ``` $ prog --<tab><tab> --help -h (Prints help information) --max-vals (you can only supply a max of 3 values for me!) --min-vals (you must supply at least two values to satisfy me) --mode (shows an option with specific values) --mult-vals (demos an option which has two named values) --option -o (example option argument from yaml) --version -V (Prints version information) ``` ``` $ prog --mode <tab> emacs (shows an option with specific values) vi (shows an option with specific values) ``` ``` $ prog subcmd -<tab> --help -h (Prints help information) -B (example subcommand option) --version -V (Prints version information) ``` ``` $ prog subcmd --<tab> --help (Prints help information) --version (Prints version information) ``` Close clap-rs#578
e662f2c
to
1979d2f
Compare
@kbknapp Done. Please review again 😃 |
Looks great! Thanks again 👍 @homu r+ |
📌 Commit 1979d2f has been approved by |
feat(Completions): one can generate a basic fish completions script at compile time As I've mentioned in #578 , I've made my first working [fish](https://github.com/fish-shell/fish-shell) completion. 😄 Things may work like this : ![clap](https://cloud.githubusercontent.com/assets/2716047/16733541/88e1046c-47b4-11e6-9174-899f77db5877.png) ![clap0](https://cloud.githubusercontent.com/assets/2716047/16733433/1e9314d8-47b4-11e6-9efe-56053b706cbd.png) ![clap1](https://cloud.githubusercontent.com/assets/2716047/16733437/22b88fd4-47b4-11e6-8504-4832e3d138ae.png) ![clap2](https://cloud.githubusercontent.com/assets/2716047/16733441/2533df8e-47b4-11e6-941a-81e64522eea6.png)
feat(Completions): one can generate a basic fish completions script at compile time As I've mentioned in #578 , I've made my first working [fish](https://github.com/fish-shell/fish-shell) completion. 😄 Things may work like this : ![clap](https://cloud.githubusercontent.com/assets/2716047/16733541/88e1046c-47b4-11e6-9174-899f77db5877.png) ![clap0](https://cloud.githubusercontent.com/assets/2716047/16733433/1e9314d8-47b4-11e6-9efe-56053b706cbd.png) ![clap1](https://cloud.githubusercontent.com/assets/2716047/16733437/22b88fd4-47b4-11e6-8504-4832e3d138ae.png) ![clap2](https://cloud.githubusercontent.com/assets/2716047/16733441/2533df8e-47b4-11e6-941a-81e64522eea6.png)
☀️ Test successful - status |
👀 Test was successful, but fast-forwarding failed: 422 Required status check "continuous-integration/appveyor/pr" is expected |
Wdv4758h fish completion merge of #579
As I've mentioned in #578 , I've made my first working fish completion. 😄
Things may work like this :