Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

How to expeand zsh compctl completions with same prefix (from z script)?

Hello there , 

Can anyone help me with a `compctl` grouping autocomplete entries by prefix behavior?

I have a zsh setup via .oh-my-zsh.
The z plugin allows to jump to last recently used directories.

When you press `z name<TAB>`  it autocompletes `name` from the list of recently visited dirs by matching `name` against the list.


Sometimes the result contains only a single entry, when i know there should be multiple. I have debugged the `reply` variable. This issue happens, if all entries have the same prefix, e.g. `/path/to/dir`, containing dirs with `name`
In this case there is only the prefix in the autocomplete menu instead of full list of matched dirs. Hitting `<TAB> `again after expansion, triggers a new call to `z` script complete function now with the full common prefix instead of my search query , e.g. `/path/to/dir`

When i press <Shift+Tab> which is bound to `reverse-menu-complete`
`zsh` properly selects the last item and shows the full list.

Is there supposed to be a further keybinding to expand the common prefix for `compctl` after it grouped all entries with a common prefix?

Messages sorted by: Reverse Date, Date, Thread, Author