[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: problem in gnu grep 2.4.2
From: |
Alain Magloire |
Subject: |
Re: problem in gnu grep 2.4.2 |
Date: |
Wed, 24 Jan 2001 09:46:31 -0500 (EST) |
>
> Hi,
>
> I noticed that the following does not work in grep 2.4.2 but it does
> (and should) work in grep 2.3:
> $ ps ax | grep '[^]]name'
> The objective of this pattern is to match all lines that have 'name'
> but not prepended with a ']'.
Right, and that is what grep is doing:
# uname -rs
SunOS 5.8
# /bin/echo "]name\nbname"| grep -E '[^]]name'
bname
# grep --version
grep (GNU grep) 2.4.2
If you have a different behaviour, for 2.3 then that is a bug in 2.3
(I did not test 2.3).
> BTW the following does work in 2.4.2
> $ ps ax | grep '[^[:graph:]]ssh'
# /bin/echo "]name\nbname"| grep -E '[^[:graph:]]name'
# /bin/echo "]name\nbname"| grep -E '[^[:punct:]]name'
bname
--
alain