Thursday, November 25, 2010

RE: Open Search Results in New Tab


2010/11/24 Roy Fulbright <rfulbrig@hotmail.com>
How can I display search results in a new tab? For example, I have a file with thousands of lines and I enter:
 
g/abc/
 
The lines matching "abc" are scolled (via more) in a section of the current screen and disappear when
the last lines are displayed. I would like to have the matching lines displayed in a new tab instead. Is this
possible?
 
Thanks,
Roy
 

--


there's a good artible by Robert Bram devoted to that:
http://robertmarkbramprogrammer.blogspot.com/2008/12/searching-files-within-vim-and-opening.html

He explains different methods to open results and some more tips to find and manage files too. :)

iƱ

Thanks. That's a great article, but it addresses capturing output from the shell command line. I need
to capture the output from the :g/abc/ command within Vim in a new tab.
 
Roy

No comments:

Post a Comment