1

When I start gvim.exe, it starts with the usual vim start window. But there are previous buffers hidden in background.

How I can disable this behavior?

2 Answers 2

4

Unless you have any plugin applying its magic, this is probably caused by the % value in 'viminfo':

% When included, save and restore the buffer list. If Vim is started with a file name argument, the buffer list is not restored. If Vim is started without a file name argument, the buffer list is restored from the viminfo file. Buffers without a file name and buffers for help files are not written to the viminfo file.

0

When you start Vim without a file or directory ($ vim), your bufferlist should have only one item, an empty, unnamed buffer.

When you start Vim with a file ($ vim filename), your bufferlist (:ls) should have only one item, the buffer corresponding to that file.

Vim doesn't load buffers unless you tell it to do so. If you get additional items in any of the above scenarii you must examine your vimrc and, eventually see if some plugin is not responsible for this.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .