On 11/03/2011 12:48, Paolo Bonzini wrote:
On 03/10/2011 02:32 PM, Bogdan Sass wrote:I have encountered the following problem when attempting to combine the "case insensitive" and "count matches" option of egrep:root@vm-ubuntu:~# egrep -i "^[^a-r]*$" /usr/share/dict/british-english | wc -l 50root@vm-ubuntu:~# egrep -i "^[^a-r]*$" /usr/share/dict/british-english -c98297 root@vm-ubuntu:~# egrep -ic "^[^a-r]*$" /usr/share/dict/british-english 98297 The match is done correctly, but when I try to count the matches directly from egrep I get way too many results. Is there anything I am doing wrong here?What version of grep is this? It works for me with 2.7.
root@vm-ubuntu:~# egrep -V GNU grep 2.6.3The default version installed by Ubuntu 10.10. There doesn't seem to be an updated version in the Ubuntu repositories...
Thank you,
--
Bogdan Sass
CCAI,CCSP,JNCIA-ER,CCIE #22221 (RS)
Information Systems Security Professional
"Curiosity was framed - ignorance killed the cat"
smime.p7s
Description: S/MIME Cryptographic Signature
