开发者

Vim in ex-command mode, how to complete the path only up to the first non unique match?

I'm in a directory with many subfolders with a common prefix:

./pref-apple
./pref-aubergine
./pref-mango
./pref-milk

I have a file in one of these folder and I want vim to auto-complete the path just up to the first non-ambiguous match

开发者_运维百科

:e ./p<TAB> -> :e ./pref-

:e ./pref-au<TAB> -> :e ./pref-aubergine/

while at the moment it will auto-complete with the full first folder-name. :e ./p<TAB> -> :e/pref-apple/

How can I do that?


You want to set wildmode=longest.

More info at :help 'wildmode'

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜