How can I open another vertical window (:vsp) on the left in vim?

Sasha picture Sasha · Jul 22, 2009 · Viewed 7.5k times · Source

vim's :vsp command opens a window on right. Is there a way to open it on the left side of the screen?

Answer

David Raznick picture David Raznick · Jul 22, 2009

You have to do :rightb vsp. or :bel vsp.

The rightb and bel[owright] stands for right below. You can put any splitting command after it and it will split in that direction dependant on if v is in the splitting command.

There is also :lefta vsp and :abo vsp, if you want to make sure you split in the other direction and works in the same way as above.