I use Unite.vim frequently to scroll through lists of files in Vim. Sometimes I use Unite's auto-preview
feature to have each file open in the preview window as I scroll over it. If I scroll through a large number of files, this leaves me with a bunch of open buffers that I do not need. How can I make the buffer currently occupying the preview window close when a new buffer is opened into the preview window?
Autoclose buffer occupying Vim's preview window when new buffer opens in preview window
422 views Asked by Sean Mackesey At
1
I was able to solve this problem by looking through the Unite source, copying the preview function, and making the modification I needed directly on this function to do a vertical open of the preview window: