VIM Delete All Except

2007-04-05 Thread jas01
xcept for 'Text' and 'Text2' and 'Text3'. Please help! -- View this message in context: http://www.nabble.com/VIM-Delete-All-Except-tf3531855.html#a9856565 Sent from the Vim - General mailing list archive at Nabble.com.

Re: VIM Delete All Except

2007-04-05 Thread Jürgen Krämer
Hi, jas01 wrote: > I have a huge file where I need to delete all lines except for a few I need. > I'm trying to do this in a single command. > > I know that: > > :v/Text/d > > will delete all lines except for ones containing 'Text.' I have no idea how > to put multiple strings so the command

Re: VIM Delete All Except

2007-04-05 Thread Charles E Campbell Jr
jas01 wrote: I have a huge file where I need to delete all lines except for a few I need. I'm trying to do this in a single command. I know that: :v/Text/d will delete all lines except for ones containing 'Text.' I have no idea how to put multiple strings so the command deletes everything e

Re: VIM Delete All Except

2007-04-05 Thread Charles E Campbell Jr
Charles E Campbell Jr wrote: jas01 wrote: I have a huge file where I need to delete all lines except for a few I need. I'm trying to do this in a single command. I know that: :v/Text/d will delete all lines except for ones containing 'Text.' I have no idea how to put multiple strings so th

Re: VIM Delete All Except

2007-04-05 Thread cga2000
On Thu, Apr 05, 2007 at 10:10:03AM EDT, jas01 wrote: > > I have a huge file where I need to delete all lines except for a few I need. > I'm trying to do this in a single command. > > I know that: > > :v/Text/d > > will delete all lines except for ones containing 'Text.' I have no idea how > to

Re: VIM Delete All Except

2007-04-09 Thread Zhaojun WU
On 4/6/07, cga2000 <[EMAIL PROTECTED]> wrote: On Thu, Apr 05, 2007 at 10:10:03AM EDT, jas01 wrote: > If the file is really huge, you may find adopting a different strategy is preferable. If you're on linux or similar you might use a command-line tool such as: $ grep Text[1-3] huge_file > a_f