diff --git a/doc/ctrlp.txt b/doc/ctrlp.txt index 29b5999..a0d6471 100644 --- a/doc/ctrlp.txt +++ b/doc/ctrlp.txt @@ -33,7 +33,50 @@ To enable optional extensions (tag, dir, rtscript...), see |ctrlp-extensions|. =============================================================================== OPTIONS *ctrlp-options* -Below are the available options and their default values:~ +Overview:~ + + |loaded_ctrlp| Disable the plugin. + |ctrlp_map| Default mapping. + |ctrlp_cmd| Default command used for the default mapping. + |ctrlp_by_filename| Default to filename mode or not. + |ctrlp_regexp| Default to regexp mode or not. + |ctrlp_match_window_bottom| Where to show the match window. + |ctrlp_match_window_reversed| Sort order in the match window. + |ctrlp_max_height| Max height of the match window. + |ctrlp_switch_buffer| Jump to an open buffer if already opened. + |ctrlp_reuse_window| Reuse special windows (help, quickfix, etc). + |ctrlp_working_path_mode| How to set CtrlP’s local working directory. + |ctrlp_root_markers| Additional, high priority root markers. + |ctrlp_use_caching| Use per-session caching or not. + |ctrlp_clear_cache_on_exit| Keep cache after exiting Vim or not. + |ctrlp_cache_dir| Location of the cache directory. + |ctrlp_dotfiles| Ignore dotfiles and dotdirs or not. + |ctrlp_custom_ignore| Hide stuff when using |globpath()|. + |ctrlp_max_files| Number of files to scan initially. + |ctrlp_max_depth| Directory depth to recurse into when scanning. + |ctrlp_user_command| Use an external scanner. + |ctrlp_max_history| Number of entries saved in the prompt history. + |ctrlp_open_new_file| How to open a file created by . + |ctrlp_open_multiple_files| How to open files selected by . + |ctrlp_arg_map| Intercept and or not. + |ctrlp_follow_symlinks| Follow symbolic links or not. + |ctrlp_lazy_update| Only update when typing has stopped. + |ctrlp_default_input| Seed the prompt with an initial string. + |ctrlp_use_migemo| Use Migemo patterns for Japanese filenames. + |ctrlp_prompt_mappings| Change the mappings in the prompt. + MRU mode: + |ctrlp_mruf_max| Max MRU entries to remember. + |ctrlp_mruf_exclude| Files that shouldn’t be remembered. + |ctrlp_mruf_include| Files to be remembered. + |ctrlp_mruf_relative| Show only MRU files in the working directory. + |ctrlp_mruf_case_sensitive| MRU files are case sensitive or not. + Advanced options: + |ctrlp_status_func| Change CtrlP’s two statuslines. + |ctrlp_buffer_func| Call custom functions in the CtrlP buffer. + |ctrlp_match_func| Replace the built-in matching algorithm. + +------------------------------------------------------------------------------- +Detailed descriptions and default values:~ *'g:ctrlp_map'* Use this option to change the mapping to invoke CtrlP in |Normal| mode: > @@ -135,88 +178,6 @@ Set the directory to store the cache files: > let g:ctrlp_cache_dir = $HOME.'/.cache/ctrlp' < - *'g:ctrlp_prompt_mappings'* -Use this to customize the mappings inside CtrlP’s prompt to your liking. You -only need to keep the lines that you’ve changed the values (inside []): > - let g:ctrlp_prompt_mappings = { - \ 'PrtBS()': ['', ''], - \ 'PrtDelete()': [''], - \ 'PrtDeleteWord()': [''], - \ 'PrtClear()': [''], - \ 'PrtSelectMove("j")': ['', ''], - \ 'PrtSelectMove("k")': ['', ''], - \ 'PrtSelectMove("t")': ['', ''], - \ 'PrtSelectMove("b")': ['', ''], - \ 'PrtSelectMove("u")': ['', ''], - \ 'PrtSelectMove("d")': ['', ''], - \ 'PrtHistory(-1)': [''], - \ 'PrtHistory(1)': [''], - \ 'AcceptSelection("e")': ['', '<2-LeftMouse>'], - \ 'AcceptSelection("h")': ['', '', ''], - \ 'AcceptSelection("t")': ['', ''], - \ 'AcceptSelection("v")': ['', ''], - \ 'ToggleFocus()': [''], - \ 'ToggleRegex()': [''], - \ 'ToggleByFname()': [''], - \ 'ToggleType(1)': ['', ''], - \ 'ToggleType(-1)': ['', ''], - \ 'PrtExpandDir()': [''], - \ 'PrtInsert("w")': ['', ''], - \ 'PrtInsert("s")': [''], - \ 'PrtInsert("v")': [''], - \ 'PrtInsert("+")': [''], - \ 'PrtCurStart()': [''], - \ 'PrtCurEnd()': [''], - \ 'PrtCurLeft()': ['', '', ''], - \ 'PrtCurRight()': ['', ''], - \ 'PrtClearCache()': [''], - \ 'PrtDeleteMRU()': [''], - \ 'CreateNewFile()': [''], - \ 'MarkToOpen()': [''], - \ 'OpenMulti()': [''], - \ 'PrtExit()': ['', '', ''], - \ } -< -Note: In some terminals, it’s not possible to remap without also changing - (|keycodes|). So if pressing moves the cursor to the left instead of -deleting a char for you, add this to your |.vimrc| to disable the plugin’s -default mapping: > - let g:ctrlp_prompt_mappings = { 'PrtCurLeft()': ['', ''] } -< - - *'g:ctrlp_mruf_max'* -Specify the number of recently opened files you want CtrlP to remember: > - let g:ctrlp_mruf_max = 250 -< - - *'g:ctrlp_mruf_exclude'* -Files you don’t want CtrlP to remember. Use regexp to specify the patterns: > - let g:ctrlp_mruf_exclude = '' -< -Examples: > - let g:ctrlp_mruf_exclude = '/tmp/.*\|/temp/.*' " MacOSX/Linux - let g:ctrlp_mruf_exclude = '^C:\\dev\\tmp\\.*' " Windows -< - - *'g:ctrlp_mruf_include'* -And if you want CtrlP to only remember some files, specify them here: > - let g:ctrlp_mruf_include = '' -< -Example: > - let g:ctrlp_mruf_include = '\.py$\|\.rb$' -< - - *'g:ctrlp_mruf_relative'* -Set this to 1 to show only MRU files in the current working directory: > - let g:ctrlp_mruf_relative = 0 -< - - *'g:ctrlp_mruf_case_sensitive'* -Match this with your file system case-sensitivity setting to avoid duplicate -MRU entries: > - let g:ctrlp_mruf_case_sensitive = 1 -< - *'g:ctrlp_dotfiles'* Set this to 0 if you don’t want CtrlP to scan for dotfiles and dotdirs: > let g:ctrlp_dotfiles = 1 @@ -378,8 +339,93 @@ works in regexp mode. To split the pattern, separate words with space: > let g:ctrlp_use_migemo = 0 < -------------------------------------------------------------------------------- -ADVANCED OPTIONS *ctrlp-advanced-options* + *'g:ctrlp_prompt_mappings'* +Use this to customize the mappings inside CtrlP’s prompt to your liking. You +only need to keep the lines that you’ve changed the values (inside []): > + let g:ctrlp_prompt_mappings = { + \ 'PrtBS()': ['', ''], + \ 'PrtDelete()': [''], + \ 'PrtDeleteWord()': [''], + \ 'PrtClear()': [''], + \ 'PrtSelectMove("j")': ['', ''], + \ 'PrtSelectMove("k")': ['', ''], + \ 'PrtSelectMove("t")': ['', ''], + \ 'PrtSelectMove("b")': ['', ''], + \ 'PrtSelectMove("u")': ['', ''], + \ 'PrtSelectMove("d")': ['', ''], + \ 'PrtHistory(-1)': [''], + \ 'PrtHistory(1)': [''], + \ 'AcceptSelection("e")': ['', '<2-LeftMouse>'], + \ 'AcceptSelection("h")': ['', '', ''], + \ 'AcceptSelection("t")': ['', ''], + \ 'AcceptSelection("v")': ['', ''], + \ 'ToggleFocus()': [''], + \ 'ToggleRegex()': [''], + \ 'ToggleByFname()': [''], + \ 'ToggleType(1)': ['', ''], + \ 'ToggleType(-1)': ['', ''], + \ 'PrtExpandDir()': [''], + \ 'PrtInsert("w")': ['', ''], + \ 'PrtInsert("s")': [''], + \ 'PrtInsert("v")': [''], + \ 'PrtInsert("+")': [''], + \ 'PrtCurStart()': [''], + \ 'PrtCurEnd()': [''], + \ 'PrtCurLeft()': ['', '', ''], + \ 'PrtCurRight()': ['', ''], + \ 'PrtClearCache()': [''], + \ 'PrtDeleteMRU()': [''], + \ 'CreateNewFile()': [''], + \ 'MarkToOpen()': [''], + \ 'OpenMulti()': [''], + \ 'PrtExit()': ['', '', ''], + \ } +< +Note: In some terminals, it’s not possible to remap without also changing + (|keycodes|). So if pressing moves the cursor to the left instead of +deleting a char for you, add this to your |.vimrc| to disable the plugin’s +default mapping: > + let g:ctrlp_prompt_mappings = { 'PrtCurLeft()': ['', ''] } +< + +---------------------------------------- +MRU mode options:~ + + *'g:ctrlp_mruf_max'* +Specify the number of recently opened files you want CtrlP to remember: > + let g:ctrlp_mruf_max = 250 +< + + *'g:ctrlp_mruf_exclude'* +Files you don’t want CtrlP to remember. Use regexp to specify the patterns: > + let g:ctrlp_mruf_exclude = '' +< +Examples: > + let g:ctrlp_mruf_exclude = '/tmp/.*\|/temp/.*' " MacOSX/Linux + let g:ctrlp_mruf_exclude = '^C:\\dev\\tmp\\.*' " Windows +< + + *'g:ctrlp_mruf_include'* +And if you want CtrlP to only remember some files, specify them here: > + let g:ctrlp_mruf_include = '' +< +Example: > + let g:ctrlp_mruf_include = '\.py$\|\.rb$' +< + + *'g:ctrlp_mruf_relative'* +Set this to 1 to show only MRU files in the current working directory: > + let g:ctrlp_mruf_relative = 0 +< + + *'g:ctrlp_mruf_case_sensitive'* +Match this with your file system case-sensitivity setting to avoid duplicate +MRU entries: > + let g:ctrlp_mruf_case_sensitive = 1 +< + +---------------------------------------- +Advanced options:~ *'g:ctrlp_status_func'* Use this to customize the statuslines for the CtrlP window: > @@ -521,6 +567,9 @@ The following commands ignore the current value of |g:ctrlp_working_path_mode|: :CtrlPRoot *:CtrlPRoot* This acts like |:CtrlP| with |path_mode| = 2 +------------------------------------------------------------------------------- +For commands provided by bundled extensions, see |ctrlp-extensions|. + =============================================================================== MAPPINGS *ctrlp-mappings* @@ -709,7 +758,7 @@ f) Type the name of a non-existent file and press to create it. Mark a g) Submit ? to open this help file. =============================================================================== -EXTENSIONS *g:ctrlp-extensions* +EXTENSIONS *ctrlp-extensions* Extensions are optional. To enable an extension, add its name to the variable g:ctrlp_extensions: >