How to re-index CtrlP Vim plugin?
Asked Answered
T

1

19

I've been using CtrlP for a while now, but I still haven't figured out how to re-index it. So whenever I want to create a new file I have to close all existing vim sessions, create the file, and then re-open them back. Otherwise the new file won't show up in the results.

I've been doing this without thinking much although this is really a huge pain in the ass. Today I decided to finally ask. Anyone know how to re-index CtrlP? I couldn't find it in the doc.

Transcend answered 20/7, 2012 at 6:53 Comment(1)
CtrlP is the name of a plugin, not a shortcut. Well, it's also the default shortcut, but Vlad is talking about the plugin.Yellows
Y
25

Did you read CtrlP's documentation? The answer is there, of course:

F5

Seriously, :help pluginname should be the first command to issue after installing a plugin. After :helptags ~/.vim/doc, maybe.

Yellows answered 20/7, 2012 at 7:15 Comment(3)
I'm sorry about this, I have to admit that I totally missed it. By the way F5 doesn't work on my macbook, as it changes screen brightness. I've tried fn-F5 but that doesn't work either...Transcend
I don't own a MacBook. The command is :CtrlPClearCache: if <F5> doesn't work for you try to map it to something that works.Yellows
I do have a MacBook, and <F5> works for me. You need to have CtrlP open first though. So, do :CtrlP, then push <F5>. On the mac, that'll likely need to be Fn-<F5>, unless you've told Mac OS X to treat the function keys as standard function keys (System Preferences -> Keyboard -> Keyboard -> Use all F1, F2, etc. keys as standard function keys).Regale

© 2022 - 2024 — McMap. All rights reserved.