Tip #412: Easy menu-style switch between files with a simple map
tip karma |
Rating 70/28, Viewed by 1611
|
created: |
|
January 29, 2003 9:15 |
|
complexity: |
|
basic |
author: |
|
Raghavan Subramaniyan |
|
as of Vim: |
|
6.0 |
When there are several files opened in a vim session, it becomes difficult to keep track of the files and their respective buffer numbers.
Switching to a different file is made easier using a simple map:
:map <F5> :buffers<CR>:e #
When F5 is pressed, a numbered list of file names is printed, and the user needs to type a single number based on the "menu".
Another good thing is that the "menu" disappears after choosing the number and hitting enter. So it appears only when you need it.
<<How to initialize plugins |
Drag and Drop file names into VIM's command line >>
Additional Notes
|