VIM ctrlp.vim plugin: how to rescan files?

As Jeet says you can press F5 but if that doesn't work you can always run :CtrlPClearCache which is what F5 is supposed to run.

From the documentation

:CtrlPClearCache
Flush the cache for the current working directory. The same as pressing <F5> inside CtrlP.
To enable or disable caching, use the |g:ctrlp_use_caching| option.


From the documentation:

<F5>
  - Refresh the match window and purge the cache for the current directory.
  - Remove deleted files from MRU list.

This assumes you're in ctrl-p mode already. Note that you can hit F5 in the middle of a query, i.e., you can type a few characters, find it's not matching a recently updated file, and hit F5 to refresh right then. It will automatically show you the match if the file was just added to the ctrl-p cache.


I added this to .vimrc which turns off ctrlp caching

g:ctrlp_use_caching = 0

Tags:

Plugins

Vim