On 12-09-27 12:00 PM, roundtable-request@muug.mb.ca wrote:
Send Roundtable mailing list submissions to roundtable@muug.mb.ca
To subscribe or unsubscribe via the World Wide Web, visit http://www.muug.mb.ca/mailman/listinfo/roundtable or, via email, send a message with subject or body 'help' to roundtable-request@muug.mb.ca
You can reach the person managing the list at roundtable-owner@muug.mb.ca
When replying, please edit your Subject line so it is more specific than "Re: Contents of Roundtable digest..."
Today's Topics:
1. Re: bash script for printing lines that don't match? (Grigory Shamov)
Message: 1 Date: Thu, 27 Sep 2012 15:13:56 +0000 From: Grigory Shamov Grigory.Shamov@ad.umanitoba.ca To: Continuation of Round Table discussion roundtable@muug.mb.ca Subject: Re: [RndTbl] bash script for printing lines that don't match? Message-ID: CC89D6B2.B1C4%Grigory.Shamov@ad.umanitoba.ca Content-Type: text/plain; charset="us-ascii"
Hi,
Not in bash, but awk: will show what is in file1 but not in file2
awk 'FNR == NR {arr[$0];next} !($1 in arr) {print}' file1 file2
I've used this to compare lists of rpms on our machines.
Have you used diff, perhaps in conjunction with sort? If so, what didnt' work?