From owner-freebsd-questions@FreeBSD.ORG Tue Mar 6 00:35:08 2007 Return-Path: X-Original-To: freebsd-questions@FreeBSD.ORG Delivered-To: freebsd-questions@FreeBSD.ORG Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 8BA6616A401 for ; Tue, 6 Mar 2007 00:35:08 +0000 (UTC) (envelope-from kline@tao.thought.org) Received: from tao.thought.org (dsl231-043-140.sea1.dsl.speakeasy.net [216.231.43.140]) by mx1.freebsd.org (Postfix) with ESMTP id 2667813C467 for ; Tue, 6 Mar 2007 00:35:08 +0000 (UTC) (envelope-from kline@tao.thought.org) Received: from tao.thought.org (localhost [127.0.0.1]) by tao.thought.org (8.13.8/8.13.1) with ESMTP id l260Z6YT012593 for ; Mon, 5 Mar 2007 16:35:07 -0800 (PST) (envelope-from kline@tao.thought.org) Received: (from kline@localhost) by tao.thought.org (8.13.8/8.13.1/Submit) id l260Z6X0012592 for freebsd-questions@FreeBSD.ORG; Mon, 5 Mar 2007 16:35:06 -0800 (PST) (envelope-from kline) Date: Mon, 5 Mar 2007 16:35:06 -0800 From: Gary Kline To: FreeBSD Mailing List Message-ID: <20070306003506.GA12553@thought.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4.2.2i X-Organization: Thought Unlimited. Public service Unix since 1986. X-Of_Interest: Observing twenty years of service to the Unix community Cc: Subject: awk 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: Tue, 06 Mar 2007 00:35:08 -0000 Guys, Having found $9 , how do I /bin/rm it (using system()--yes??) in an awk one-liner? I'm trying to remove from packages from long ago and find and print them with ls -lt | awk '{if ($8 == 2006) print $9}'; but what I want to remove the file pointed at by $9. I've tried FILE=ARGV[9]; and using FILE within my system() call, but no-joy. What's the magic here? thanks in advance, gary -- Gary Kline kline@thought.org www.thought.org Public Service Unix