Re: grep pattern x, but not pattern y on the same line

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



At Fri, 15 Oct 2010 12:11:17 +0200 CentOS mailing list <centos@xxxxxxxxxx> wrote:

> 
> Hi folks
> 
> I have the command "find . | xargs grep 'mailx'", to search all files
> with "mailx" in contents. I wish to add a second condition that NOT
> contains string sven.aluoor@xxxxxxx on the same line.
> 
> Every file which contains "mailx", but not the string
> sven.aluoor@xxxxxxx in the same line.

find . | xargs grep 'mailx'|grep -v sven.aluoor@xxxxxxx

> 
> cheers Sven
> _______________________________________________
> CentOS mailing list
> CentOS@xxxxxxxxxx
> http://lists.centos.org/mailman/listinfo/centos
> 
>                

-- 
Robert Heller             -- 978-544-6933 / heller@xxxxxxxxxxxx
Deepwoods Software        -- http://www.deepsoft.com/
()  ascii ribbon campaign -- against html e-mail
/\  www.asciiribbon.org   -- against proprietary attachments


                                                                                    
_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
http://lists.centos.org/mailman/listinfo/centos


[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux