Mercurial > public > dotfiles
diff vim/vimfiles/doc/ctrlp.txt @ 3:92af3257a261
Update to latest ctrlp.vim.
author | Brian Neal <bgneal@gmail.com> |
---|---|
date | Wed, 04 Jan 2012 19:37:22 -0600 |
parents | 48859d9c82c5 |
children |
line wrap: on
line diff
--- a/vim/vimfiles/doc/ctrlp.txt Wed Jan 04 19:34:22 2012 -0600 +++ b/vim/vimfiles/doc/ctrlp.txt Wed Jan 04 19:37:22 2012 -0600 @@ -1,4 +1,4 @@ -*ctrlp.txt* Fuzzy file, buffer, mru and tag finder. v1.6.4 +*ctrlp.txt* Fuzzy file, buffer, mru and tag finder. v1.6.5 *CtrlP* *ControlP* *'ctrlp'* *'ctrl-p'* =============================================================================== # # @@ -23,9 +23,9 @@ =============================================================================== 1. Intro *ctrlp-intro* -Full path fuzzy file, buffer and MRU file finder with an intuitive interface. +Full path fuzzy file, buffer, mru and tag finder with an intuitive interface. Written in pure Vimscript for MacVim and Vim version 7.0+. Has full support for -Vim’s |regexp| as search pattern, built-in MRU monitoring, project’s root +Vim’s |regexp| as search pattern, built-in MRU files monitoring, project’s root finder, and more. To enable optional extensions (tag, quickfix, dir...), see |ctrlp-extensions|. @@ -40,8 +40,13 @@ let g:ctrlp_map = '<c-p>' < + *'g:ctrlp_cmd'* +Set the default opening command to use when pressing the above mapping: > + let g:ctrlp_cmd = 'CtrlP' +< + *'g:loaded_ctrlp'* -Use this option to disable the plugin completely: > +Use this to disable the plugin completely: > let g:loaded_ctrlp = 1 < @@ -72,9 +77,10 @@ < *'g:ctrlp_jump_to_buffer'* -Set this to 0 to disable the jump-to-open-buffer feature. Set to 2 to also jump -tab if the selected buffer’s opened in another tab: > - let g:ctrlp_jump_to_buffer = 1 +Set this to 0 to disable the jump-to-open-buffer feature. +Set to 2 to also jump tab if the selected buffer’s opened in another tab. +Set to 1 to only jump to it if it’s opened in the current tab: > + let g:ctrlp_jump_to_buffer = 2 < *'g:ctrlp_working_path_mode'* @@ -137,7 +143,7 @@ \ 'ToggleFocus()': ['<tab>'], \ 'ToggleRegex()': ['<c-r>'], \ 'ToggleByFname()': ['<c-d>'], - \ 'ToggleType(1)': ['<c-f>', '<c-up'], + \ 'ToggleType(1)': ['<c-f>', '<c-up>'], \ 'ToggleType(-1)': ['<c-b>', '<c-down>'], \ 'PrtCurStart()': ['<c-a>'], \ 'PrtCurEnd()': ['<c-e>'], @@ -192,21 +198,24 @@ Set this to 0 if you don’t want |CtrlP| to search for dotfiles and dotdirs: > let g:ctrlp_dotfiles = 1 < -You can also use |'wildignore'| to exclude anything from the search. -e.g. exclude version control directories from the results: > +You can use |'wildignore'| to exclude anything from the search. +e.g. exclude version control directories: > set wildignore+=*/.git/*,*/.hg/*,*/.svn/* " Linux/MacOSX set wildignore+=.git\*,.hg\*,.svn\* " Windows < -Note: the `*/` in front of each dotfile glob is required for the dotfiles -search feature to work correctly along side with |wildignore|. If you’ve -disabled dotfiles search (set |g:ctrlp_dotfiles| to 0), then you can ignore -this. +Note: the `*/` in front of each glob is required. Other note: |wildignore| influences the result of |expand()|, |globpath()| and |glob()| which many plugins use to find stuff on the system (e.g. fugitive.vim looks for .git/, some other plugins look for external exe tools on Windows). So be a little mindful of what you put in your |wildignore|. + *'g:ctrlp_custom_ignore'* +In addition to |'wildignore'|, use this for files and directories you want only +|CtrlP| to not show. Use |regexp| to specify the pattern: > + let g:ctrlp_custom_ignore = '' +< + *'g:ctrlp_highlight_match'* Use this to enable/disable highlighting of the matched patterns and to specify the highlight group that’ll be used: > @@ -491,7 +500,7 @@ backward in the directory tree by 1 level. If the parent directory is large, this might be slow. -e) Similarly submit '/' or '\' to find and go to the project’s root. If the +e) Similarly, submit '/' or '\' to find and go to the project’s root. If the project is large, using a VCS listing command to look for files might help speeding up the intial scan (see |g:ctrlp_user_command| for more details). @@ -507,7 +516,7 @@ Extensions are optional. To enable an extension, add its name to the variable g:ctrlp_extensions: > - let g:ctrlp_extensions = ['tag', 'quickfix', 'dir'] + let g:ctrlp_extensions = ['tag', 'buffertag', 'quickfix', 'dir'] < The order of the items will be the order they appear on the statusline and when using <c-f>, <c-b>. @@ -522,6 +531,13 @@ definition. Use the Vim’s option |'tags'| to specify the names and the locations of the tags file(s). Example: `set tags+=tags/help,doc/tags` + *:CtrlPBufTag* + * Buffer Tag mode:~ + - Name: 'buffertag' + - Command: ':CtrlPBufTag' + - Search for a tag within the current buffer and jump to the definition. + Requires |exuberant_ctags|. + *:CtrlPQuickfix* * Quickfix mode:~ - Name: 'quickfix' @@ -540,6 +556,34 @@ + <c-x> change the global working directory to |CtrlP|’s current local working directory (exit). +------------------------------------------------------------------------------- +Buffer Tag mode options:~ + + *'g:ctrlp_buftag_ctags_bin'* +If ctags isn’t in your $PATH, use this to set its location: > + let g:ctrlp_buftag_ctags_bin = '' +< + + *'g:ctrlp_buftag_systemenc'* +Match this with your OS’s encoding (not Vim’s). The default value mirrors Vim’s +global |'encoding'| option: > + let g:ctrlp_buftag_systemenc = &encoding +< + + *'g:ctrlp_buftag_types'* +Use this to set the arguments for ctags, jsctags... for a given filetype: > + let g:ctrlp_buftag_types = '' +< +Examples: > + let g:ctrlp_buftag_types = { + \ 'erlang' : '--language-force=erlang --erlang-types=drmf', + \ 'javascript' : { + \ 'bin': 'jsctags', + \ 'args': '-f -', + \ }, + \ } +< + =============================================================================== EXTENDING *ctrlp-extending* @@ -590,6 +634,11 @@ =============================================================================== CHANGELOG *ctrlp-changelog* + + New feature: Buffer Tag extension. + + New command: |:CtrlPBufTag|. + + New options: |g:ctrlp_cmd|, + |g:ctrlp_custom_ignore| + Before 2011/11/30~ + New features: Tag, Quickfix and Directory extensions.