On Tue, Aug 19, 2003 at 04:05:31PM +0100, Tony S. Sykes wrote:
> All,
> 
> I am struggling writing a script which greps a binary file (grep -a)
> which will remove all of the data before the characters I am looking for
> and then to remove the data after another character so I have only the
> relevant info. When you grep the binary file the line is very long. I am
> looking for only about 15 - 20 characters off the line. The problem is
> that it can be anywhere on the line so I can't use a simple cut. Would
> "ed" be able to do this? I am not looking for you to write the script,
> just pointers as to what commands I could use. So far I have got the
> grep done "grep -a '@(#)' <file>" but it's what I do to the line after
> that.
> 
> Thanks in advance,
> 
> Tony.

You can do this with sed I know as I was just looking to do something
similar. I don't have time right now, but I'll have a look through my
bookmarks and notes later tonight.

Todd


Want to buy your Pack or Services from MandrakeSoft? 
Go to http://www.mandrakestore.com

Reply via email to