Re: [Boston.pm] Perl style regex in shell command for matching across lines?

2005-10-19 Thread Duane Bronson
gt;10/19/2005 06:56 PM > >To >Ranga Nathan <[EMAIL PROTECTED]> >cc >boston-pm@mail.pm.org >Subject >Re: [Boston.pm] Perl style regex in shell command for matching across >lines? > > > > > > >On 10/19/05, Ranga Nathan <[EMAIL PROTECTED]> wrote:

Re: [Boston.pm] Perl style regex in shell command for matching across lines?

2005-10-19 Thread Ranga Nathan
; Technical Services; BAX Global Inc. Irvine-California Tel: 714-442-7591 Fax: 714-442-2840 Ben Tilly <[EMAIL PROTECTED]> Sent by: [EMAIL PROTECTED] 10/19/2005 06:56 PM To Ranga Nathan <[EMAIL PROTECTED]> cc boston-pm@mail.pm.org Subject Re: [Boston.pm] Perl style regex in s

Re: [Boston.pm] Perl style regex in shell command for matching across lines?

2005-10-19 Thread Ben Tilly
On 10/19/05, Ranga Nathan <[EMAIL PROTECTED]> wrote: > I need to check ftp logs (see below) for successful transfer of files. > This is a bash script someone else wrote and I need to modify it. I want > to use a Perl style regex like > > /^125.*?baxp\.caed.*?\n250/i > > in any ?grep or sed or

Re: [Boston.pm] Perl style regex in shell command for matching across lines?

2005-10-19 Thread Kripa Sundar
Dear Ranga, Two clarifications on my previous email. I wrote: > If the perl invocation is your performance bottleneck, that is a > pleasant problem to deal with. What I meant to write is this: > If the overhead of invoking perl is your performance bottleneck, that is a > pleasant problem to

Re: [Boston.pm] Perl style regex in shell command for matching across lines?

2005-10-19 Thread Kripa Sundar
Dear Ranga, > I tried grep and egrep - they seem to match only one line at a time. I am > unable to match for \n inside the pattern. > > What shell utility would do it? I dont want to bring in the perl > interpreter just for this! Please *do*! If the perl invocation is your performance

[Boston.pm] Perl style regex in shell command for matching across lines?

2005-10-19 Thread Ranga Nathan
I need to check ftp logs (see below) for successful transfer of files. This is a bash script someone else wrote and I need to modify it. I want to use a Perl style regex like /^125.*?baxp\.caed.*?\n250/i in any ?grep or sed or awk whichever can do this. I tried grep and egrep - they seem