自动完成vim中的隐藏文件
在vim中,当我使用类似自动完成vim中的隐藏文件,vim,autocomplete,hidden-files,Vim,Autocomplete,Hidden Files,在vim中,当我使用类似:e的东西打开文件时,它不会自动完成带有隐藏前缀的文件。例如,当试图编辑.gitignore文件时,我必须键入整个文件名,而不能直接进入:e.giti。如果我只是键入:e,vim只列出非隐藏文件 我注意到,当我使用:FufFileWithCurrentBufferDir时,甚至FuzzyFinder实际上也不会显示隐藏的文件 有什么方法可以启用此功能吗?Vim在扩展通配符时使用wildignore过滤完成列表。确保.gitignore与该列表中的文件模式不匹配 :帮助“w
:e
的东西打开文件时,它不会自动完成带有隐藏前缀
的文件。例如,当试图编辑.gitignore
文件时,我必须键入整个文件名,而不能直接进入:e.giti
。如果我只是键入:e
,vim只列出非隐藏文件
我注意到,当我使用:FufFileWithCurrentBufferDir
时,甚至FuzzyFinder实际上也不会显示隐藏的文件
有什么方法可以启用此功能吗?Vim在扩展通配符时使用
wildignore
过滤完成列表。确保.gitignore
与该列表中的文件模式不匹配
:帮助“wildignore”
复制到下面
'wildignore' 'wig'
'wildignore' 'wig' string (default "")
global
{not in Vi}
{not available when compiled without the +wildignore
feature}
A list of file patterns. A file that matches with one of these
patterns is ignored when expanding wildcards, completing file or
directory names, and influences the result of expand(), glob() and
globpath() unless a flag is passed to disable this.
The pattern is used like with :autocmd, see autocmd-patterns.
Also see 'suffixes'.
Example:
:set wildignore=*.o,*.obj
The use of :set+= and :set-= is preferred when adding or removing
a pattern from the list. This avoids problems when a future version
uses another default.
“wildignore”“wig”
“wildignore”“wig”字符串(默认值“”)
全球的
{不在Vi}
{在没有+wildignore的情况下编译时不可用
特征}
文件模式的列表。与其中一个匹配的文件
扩展通配符、完成文件或操作时忽略模式
目录名,并影响expand()、glob()和
globpath(),除非传递了一个标志来禁用此功能。
该模式的使用方式与:autocmd类似,请参见autocmd模式。
另请参见“后缀”。
例子:
:set wildignore=*.o,*.obj
添加或删除时,最好使用:set+=和:set-=
列表中的模式。这样可以避免在将来的版本中出现问题
使用另一个默认值。
要找出上次设置的位置,您可以使用
:verbose set wildignore?
供参考,我可以毫无问题地使用e.
(Vim 7.4 1-944,ArchLinux)。检查wildignore<代码>详细设置wildignore?@VanLasere.
似乎列出了隐藏的目录,但没有列出隐藏的文件(Vim 7.4 1-52,Linux Mint)@FDinoff changingwildignore
似乎有效。请添加一个答案,以便我可以接受。这似乎让隐藏的虚线文件和隐藏的虚线文件夹通过:set wildignore+=.*
但请注意,这会影响所有必须使用此设置的插件。