[Feature request] Native zsh completion
See original GitHub issuePicocli currently can create bash completion files, and zsh has a compatibility tool to read bash completion files.
However, this only exposes basic autocompletion features (what bash itself support), and does not take advantage of the features zsh offer.
For instance, zsh can show a description for each command/option, as well as option aliases (short vs long options). There’s a thousands pictures on the internet; here’s one example for the git command:
This behavior cannot be obtained from a bash completion file.
Therefore, I propose that a new Autocomplete.zsh
static method be added, to output a zsh-native completion script that includes more details, like command and option description and aliases.
Issue Analytics
- State:
- Created 6 years ago
- Reactions:12
- Comments:11 (6 by maintainers)
Top Results From Across the Web
zsh auto-completion - Kubernetes
The kubectl completion script for Zsh can be generated with the command kubectl completion zsh . Sourcing the completion script in your shell ......
Read more >Zsh - ArchWiki
Command completion. Perhaps the most compelling feature of Zsh is its advanced autocompletion abilities. At the very least, enable autocompletion in .zshrc ....
Read more >Command completion - AWS Command Line Interface
When you partially enter a command, parameter, or option, the command-completion feature either automatically completes your command or displays a suggested ...
Read more >Command completion - Amazon Command Line Interface
The Amazon Command Line Interface (Amazon CLI) includes a bash-compatible command-completion feature that enables you to use the Tab key to complete a ......
Read more >IDE-style autocomplete for your zsh terminal - Reddit
Can it use existing native zsh completion code? ... full control over your terminal just can't ever weigh up against its feature set....
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Reference material:
@yschimke I saw your message on #502. Thanks! I am still working on some parser issues, but ZSH completion is high on my list of priorities. Once I make some progress on this your feedback will be very welcome!
UPDATE 2020/11/16
I was thinking about redesigning the logic for generating completion scripts to follow the Visitor pattern; I need to prototype this a bit to see how useful this would be. Something like this:
Current call tree: