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

disable substring match on command name



Hello,

I have following line in .zsh (via zsh-newuser-install)
zstyle ':completion:*' matcher-list '' 'r:|[._-]=** r:|=**' 'l:|=* r:|=*'


This does substring match on command and filenames.

i.e. if there is command in system say /usr/bin/foobar and I type

$> oob<TAB>

it changes to foobar.

This
 can cause accidental running of some different command if there is 
spelling mistake. (Especially when you are in a hurry). As with spelling
 mistake there is high chance of matching a random command.


What I would like is substring match to work only on file and directory names. (i.e. arguments to command)

I do not want substring match on command.

Please
 suggest how to do it? I searched on Google but could not find anything.
 (Either I dont know right keyword to search or not many want this 
feature)

Amm.




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