-
Notifications
You must be signed in to change notification settings - Fork 24
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
Add shell completion #348
Add shell completion #348
Conversation
Issue-Id: #237
Still missing:
|
The current version only works for static completions. To prepare for dynamic completions, the method as described in https://github.com/clap-rs/clap/pull/5586/files probably has to be used. |
Issue-Id: #237
Now this PR is prepared for dynamic completion as described in clap_complete::dynamic::ArgValueCompleterCopy. In there we need to query the server for available workloads. |
I started a discussion in clap-rs/clap#5677. |
The current version provides static completion. It also contains dynamic completion for the |
clap_complete with the features "unstable-dynamic" and "unstable-command" is really unstable for the time being. The ank code that compiles with clap_complete 4.5.14 does not compile when using 4.5.18 anymore. Maybe we should wait with merging this PR or also introduce a feature flag for the dynamic completion. |
Currently the build fails as clippy complains about unused variables. This is a bug in clippy which exists in Rust 1.80.0 (current Rust version in dev container) and is fixed in Rust 1.80.1. |
Besides that, this PR is feature complete but lacks tests and also SWDD changes. |
Created bug report clap-rs/clap#5701. |
All done. Read for review. |
Issue-Id: #237
Issue-Id: #237
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👍
This PR adds shell completion for static and dynamic parts using clap_complete.
Issues: #237
Definition of Done
The PR shall be merged only if all items mentioned in CONTRIBUTING.md have been followed. In case an item is not applicable as described, please provide a short explanation in the description.