ViM+;CtrlP:g:CtrlP_自定义_忽略未使用
在ViM+;CtrlP:g:CtrlP_自定义_忽略未使用,vim,ctrlp,Vim,Ctrlp,在~/.vimrc中,我设置了: " Configure CtrlP " Ctrl-O opens CtrlP for the current word. map <C-o> <C-P><C-\>w " Ensure we aren't using a custom command. if exists("g:ctrl_user_command") unlet g:ctrlp_user_command endif " Specify the cach
~/.vimrc
中,我设置了:
" Configure CtrlP
" Ctrl-O opens CtrlP for the current word.
map <C-o> <C-P><C-\>w
" Ensure we aren't using a custom command.
if exists("g:ctrl_user_command")
unlet g:ctrlp_user_command
endif
" Specify the cache directory.
let g:ctrlp_cache_dir = $HOME . '/.cache/ctrlp'
" Ignore certain files and directories.
let g:ctrlp_custom_ignore = {
\ 'dir': '\v(\.git|\.hg|\.svn\|vendor|tmp)$',
\ 'file': '\v\.(swp|swo)$',
\ 'link': '',
\ }
" Disable opening files in a new buffer ("e").
" Default to opening files in a new tab ("t").
let g:ctrlp_prompt_mappings = {
\ 'AcceptSelection("e")': [],
\ 'AcceptSelection("t")': ['<cr>', '<2-LeftMouse>'],
\ }
如果我删除g:ctrlp\u custom\u ignore
并添加以下内容:
set wildignore+=*/tmp/*,*.so,*.swp,*.swo,*/vendor/*,*/\.git/*
CtrlP不为供应商/
中的文件编制索引。为什么CtrlP不使用g:CtrlP\u custom\u ignore
相关问题:
set wildignore+=*/tmp/*,*.so,*.swp,*.swo,*/vendor/*,*/\.git/*