5

When using ctrlp, I can open a selected file in a new vertical split using ctlr-v

However, the new file open in the left split and the already opened one goes to the right split. I'd like the opposite to happen : opening the new file in the right split.

Workaround : Using ctrl-w + ctrl-r afer opening the file to invert splits

0

3 Answers 3

18

You can also use <c-v> to open file in vertical split.

0
6

If you create the setting in your vimrc:

set splitright

it will open every file you open in a vertical split on the right side (not only CtrlP).

1

I'm a few years late here, but from the plugin :help docs, it says that you can configure the new tab position:

a - after.
b - before.
c - the current tab page.
l - the last tab page.
f - the first tab page.

For your desired behaviour, you should include this in your .vimrc or the configuration file of your editor.

let g:ctrlp_tabpage_position = 'ac'

I hope that someone in the future find this useful.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.