当我打算打开相关的源代码“foo.cpp”时,我经常意外打开一个二进制可执行文件,即“foo”.问题的根源是选项卡完成,即:e fo< tab>通常位于二进制代码而不是源代码.
不完全是你需要的,但我的.vimrc中有这样的东西
" ignore these files when completing names and in Ex set wildignore=.svn,CVS,.git,*.o,*.a,*.class,*.mo,*.la,*.so,*.obj,*.swp,*.jpg,*.png,*.xpm,*.gif,*.pdf,*.bak,*.beam " set of file name suffixes that will be given a lower priority when it comes to matching wildcards set suffixes+=.old