New answers tagged

0

You can probably write a bunch of Vim script to achieve the desired behaviour, but I'll suggest you take another route. In Vim, what we know as tabs in other applications, are called buffers. They are a bit confusing at first because by default there's no buffer bar, so there's no way to quickly see all the open buffers. You can install a plugin that makes ...


0

If you know the file is opened use o. It will switch you to desired tab. o: open in prev window


1

For me such line in .vimrc does the job: autocmd FileType python,c,cpp TagbarOpen


2

Vim’s -S option can take any file of vim commands and run them at startup. It’s usually used for sessions (:mksession; pairs well with tpope’s obsession plugin). In this case, though, you could make the following file " mylayout.vim edit file1 tabedit file2 " &c. And then you can do vim -S mylayout.vim


1

I have the answer of my first question: I have to invoque Vim like this vim -c ":edit file1 | tabedit file2 | vsp file3 | tabedit file4. But, I’m still answering if it doesn’t a more “elegant” way and less verbose to do the same thing?


Top 50 recent answers are included