You are not logged in.
Pages: 1
Hi,
I need some help from the Vim boffins. Ok, given that vim 7 has its new shiny grep engine built in, I was hoping to take advantage of it. However, I can't seem to get it to work as I want it to and wondered if any one has had much experience.
Quite often, when I use grep, I use it to return only lines of interest from a large input file. Therefore, what I would like is given a large text file, then typing some magical vim commands, I'm left with filtered output - i.e. only the lines that contain something of interest to me (ones that matched my regex).
I'd love to be able to do this interactively, within the buffer itself.
At the moment all I've managed to do is to get the grep functionality to act identically the /regex/ command in that it simply highlights the matches and doesn't omit lines with no match.
I hope this makes sense. TIA
Offline
How about this:
:g/regepx/p > tmpfile
:splite tmpfile
Offline
Hopefully someone will come through with this...I'd be interested as well. I hadn't heard about the built-in grep functionality with Vim 7 until your post.
Offline
Pages: 1