From owner-freebsd-questions@FreeBSD.ORG Thu Sep 13 19:38:46 2007 Return-Path: Delivered-To: questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 018B816A421 for ; Thu, 13 Sep 2007 19:38:46 +0000 (UTC) (envelope-from kurt.buff@gmail.com) Received: from el-out-1112.google.com (el-out-1112.google.com [209.85.162.183]) by mx1.freebsd.org (Postfix) with ESMTP id 9C1AF13C480 for ; Thu, 13 Sep 2007 19:38:45 +0000 (UTC) (envelope-from kurt.buff@gmail.com) Received: by el-out-1112.google.com with SMTP id r27so157877ele for ; Thu, 13 Sep 2007 12:38:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; bh=RUiYzIH6kOljKKGM4ZC7lkiU+kuM/S+3MBH6/D/t2Ow=; b=FsHmtutGhju1cPKXig41/GtrJomXNVbUPzXOOOa4hWUmHg3yq5rG34nBxMVbWULX8AMbN71UhqA2H4zebQK6X1pERXaCACibB+OXeliQUtY6BDWLEfUAvva7L9T9iXZMMBj8bu8CK/RhX3LP2FiE+7JMlvnmEzcf/EFir8ypakg= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=Q1MIiIDO/AGtwQ/G6zDRU6j6UoGM1rryvN8ipsSPBTYRL44MlgHyQFToxpXShmwgQ4uvvDeuy9g7irwl9p4Ahvcj6p953ZARH6PJI6q9pR3XlTqAMKQC+11v/QyyHHQsJlNGzR0gTmA6g2gee1MnmTiK+2dr+fFCA5i8p4Hq6vk= Received: by 10.142.128.6 with SMTP id a6mr233855wfd.1189712324106; Thu, 13 Sep 2007 12:38:44 -0700 (PDT) Received: by 10.142.78.21 with HTTP; Thu, 13 Sep 2007 12:38:43 -0700 (PDT) Message-ID: Date: Thu, 13 Sep 2007 12:38:43 -0700 From: "Kurt Buff" To: "Jeffrey Goldberg" In-Reply-To: <13D9DDEB-5AC6-4E2C-93F3-40054A97E3C9@goldmark.org> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <20070913172001.GA78799@gizmo.acns.msu.edu> <20070913175510.GA78984@gizmo.acns.msu.edu> <13D9DDEB-5AC6-4E2C-93F3-40054A97E3C9@goldmark.org> Cc: questions@freebsd.org Subject: Re: Scripting question X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Sep 2007 19:38:46 -0000 On 9/13/07, Jeffrey Goldberg wrote: > On Sep 13, 2007, at 1:19 PM, Kurt Buff wrote: > > > I think I may have a better solution. The file I'm trying to massage > > has a predecessor - the non-unique lines are the result of a > > concatenation of two files. > > > > Silly me, it's better to 'grep -v' with the one file vs. the second > > rather than trying to merge, sort and further massage the result. The > > fix will be to use sed against the first file to remove the ' NO', > > thus providing a clean argument for grepping the other file. > > Instead of grep -v take a look at comm. > > -j Interesting! I just looked at the man page, and while I don't think it it's going to be directly useful (or I'm just not reading the page correctly), it's a new utility to me - I'll keep it in mind for other things. Thanks!