Building cross reference -- how?

Chris F.A. Johnson chris-E7bvbYbpR6jSUeElwK9/Pw at public.gmane.org
Sun Oct 13 17:10:07 UTC 2013


On Sun, 13 Oct 2013, William Park wrote:

> On Sun, Oct 13, 2013 at 04:22:44AM -0400, Walter Dnes wrote:
>> On Sun, Oct 13, 2013 at 02:14:04AM -0400, William Park wrote
>>>     fgrep -e red
>>>     fgrep -e red | fgrep -e one
>
>> grep -Hno -f <output_file_from_Pass_1> list_of_input_files
>
> Is there "AND" operator in grep and its friend?
>    grep -e pat1 -e pat2
> is "OR".  I need "AND".

    Use awk:

awk '/pat1/&&/pat2/'


-- 
Chris F.A. Johnson, <http://cfajohnson.com>
--
The Toronto Linux Users Group.      Meetings: http://gtalug.org/
TLUG requests: Linux topics, No HTML, wrap text below 80 columns
How to UNSUBSCRIBE: http://gtalug.org/wiki/Mailing_lists





More information about the Legacy mailing list