[clug] Help with a python regexp?
Brendan Jurd
direvus at gmail.com
Fri Feb 20 15:41:20 GMT 2009
On Fri, Feb 20, 2009 at 9:08 PM, Brad Hards <bradh at frogmouth.net> wrote:
> So how to I match a line containing "warning:", as long as it doesn't start
> with "exchange.idl"?
>
Sounds like you are in need of a negative look-behind assertion. One
way to express this (in Python and some other Perl-compatible regex
dialects) would be:
^(?<!exchange.idl).*warning
Cheers,
BJ
More information about the linux
mailing list