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

Case-insensitive completion



I'm trying to find a way where completion of file names is case-insensitive
but where the case-insensitive matches are suggested after the case-sensitive
ones.

To test this, I've created to directories, called "Nic" and "nik".

If I use these two lines:

zstyle ':completion:*' completer _expand _complete _ignored
zstyle ':completion:*' matcher-list 'm:{a-z}={A-Z}'

I get case-insensitive matching, so that typing "cd ni<tab>" gives me
first "Nic", then "nik". This is fine, but as I said, I would like the
case-sensitive completions matching first, so that "nik" would be
suggested before "Nic".

As I interpret the manual, the following lines:

zstyle ':completion:*' completer _expand _complete _complete:jhcase _ignored
zstyle ':completion:*:jhcase:*' matcher-list 'm:{a-z}={A-Z}'

would achieve what I want. However, now typing "cd ni<tab>" gives me only
"nik", and apparently "Nic" no longer matches. I suppose my jhcase-completion
completer is never called.

What am I missing?

TIA,

Jesper



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