Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!mips!dimacs.rutgers.edu!aramis.rutgers.edu!paul.rutgers.edu!njin!njitgw.njit.edu!hertz.njit.edu!ken From: ken@hertz.njit.edu (ken ng cccc) Newsgroups: comp.editors Subject: Re: Xedit is better than vi and emacs Message-ID: <1991Apr22.150404.10435@njitgw.njit.edu> Date: 22 Apr 91 15:04:04 GMT References: <1991Apr18.141001.20339@njitgw.njit.edu> Sender: news@njit.edu Distribution: usa Organization: New Jersey Institute of Technology, Newark, N.J. Lines: 21 Nntp-Posting-Host: hertz.njit.edu In article mstgil@sol.acs.unt.edu writes: :ken@hertz.njit.edu (ken ng cccc) writes: :>EXCELLENT! Thank you! Now can you tell me how to get a retrive and :>command edit for ':!' and '!!'? Please? :[edit putting the command in text, and then executing it] Only usable if it can be done without setting the 'file modified' flag. :> >all/ugga/&/booga/ = grep 'ugga.*booga' or /ugga.*booga :> >because .* matches anything except a newline :>Not quite the same, I want all occurances of 'ugga.*booga' and 'booga.*ugga'. :>AND I want to be able to selectively open up the text around the lines :>as well. Yes I can do 2 greps and merge them together, but I then I :>loose the line order they occurred on. :Got me there. I misunderstood your example. :) I've been told that I can use egrep to do do the deed, unfortunately there doesn't seem to be a way to selectively open up the surrounding text. Kenneth Ng "No problem, this is how you make it" -- R. Barclay, ST: TNG