by "Rajan" <svrajan@[EMAIL PROTECTED]
>
Mar 23, 2008 at 07:28 PM
awk can definitely understand multi-line patterns. All that you have to do
is set the RS (record separator) variable. The best place to do this would
be in the BEGIN however you can change this anytime during the execution.
The best part is RS can also be a regular expression like RS="</[^>]*>" .
<problems@[EMAIL PROTECTED]
> wrote in message
news:1206028330.11645@[EMAIL PROTECTED]
> It seems to me that sed & awk are single line based ?
>
> I want to delete blocks of text which look like:
> <opening pattern>
> <2 to 5 lines>
> <closing pattern>
>
> If I use the <2 to 5 lines>, I can avoid deleting all the good
> stuff, up to the 'next' <closing pattern> in case the assumed
> <closing pattern> is missing/undetected.
>
> Thanks for any feedback,
>
> == Chris Glur.
>