From owner-freebsd-questions@FreeBSD.ORG Sun Jan 18 10:22:47 2004 Return-Path: <owner-freebsd-questions@FreeBSD.ORG> Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D39BE16A4CE for <freebsd-questions@freebsd.org>; Sun, 18 Jan 2004 10:22:47 -0800 (PST) Received: from hotmail.com (bay8-f43.bay8.hotmail.com [64.4.27.43]) by mx1.FreeBSD.org (Postfix) with ESMTP id E905943D1F for <freebsd-questions@freebsd.org>; Sun, 18 Jan 2004 10:22:46 -0800 (PST) (envelope-from lee_ver_mx@hotmail.com) Received: from mail pickup service by hotmail.com with Microsoft SMTPSVC; Sun, 18 Jan 2004 10:22:46 -0800 Received: from 200.78.18.69 by by8fd.bay8.hotmail.msn.com with HTTP; Sun, 18 Jan 2004 18:22:46 GMT X-Originating-IP: [200.78.18.69] X-Originating-Email: [lee_ver_mx@hotmail.com] X-Sender: lee_ver_mx@hotmail.com From: "Lee Mx" <lee_ver_mx@hotmail.com> To: nkinkade@ub.edu.bz, kline@thought.org Date: Sun, 18 Jan 2004 10:22:46 -0800 Mime-Version: 1.0 Content-Type: text/plain; format=flowed Message-ID: <BAY8-F43geskuibevDu0002c4d8@hotmail.com> X-OriginalArrivalTime: 18 Jan 2004 18:22:46.0773 (UTC) FILETIME=[12701250:01C3DDF0] cc: freebsd-questions@freebsd.org Subject: Re: stumped... . X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions <freebsd-questions.freebsd.org> List-Unsubscribe: <http://lists.freebsd.org/mailman/listinfo/freebsd-questions>, <mailto:freebsd-questions-request@freebsd.org?subject=unsubscribe> List-Archive: <http://lists.freebsd.org/pipermail/freebsd-questions> List-Post: <mailto:freebsd-questions@freebsd.org> List-Help: <mailto:freebsd-questions-request@freebsd.org?subject=help> List-Subscribe: <http://lists.freebsd.org/mailman/listinfo/freebsd-questions>, <mailto:freebsd-questions-request@freebsd.org?subject=subscribe> X-List-Received-Date: Sun, 18 Jan 2004 18:22:48 -0000 >From: Nathan Kinkade <nkinkade@ub.edu.bz> >Reply-To: Nathan Kinkade <nkinkade@ub.edu.bz> >To: Gary Kline <kline@thought.org> >CC: FreeBSD Mailing List <freebsd-questions@freebsd.org> >Subject: Re: stumped... . >Date: Sun, 18 Jan 2004 09:54:23 -0600 > >On Sat, Jan 17, 2004 at 09:06:45PM -0800, Gary Kline wrote: > > On Sun, Jan 18, 2004 at 02:48:42PM +1100, Gautam Gopalakrishnan wrote: > > > On Sat, Jan 17, 2004 at 07:09:12PM -0800, Gary Kline wrote: > > > > > > > > I've written scores of scripts to hack text files, but this > > > > one has me dead in the water. > > > > > > > > How can I delete all lines from /^PATTERN to EOF?? > > > > > > > > > > sed -e '/pattern/,$d' > > > > > > > Yep. Thisis what i used, in fact. thanks. > > > > gary > >Here is another option using sed that takes 2 less keystrokes :) > >$ sed -e '/pattern/q' This would give line 1 to the pattern, wouldn't it, Rather than pattern to EOF. > >Nathan >-- >gpg --keyserver pgp.mit.edu --recv-keys D8527E49 ><< attach3 >> _________________________________________________________________ There are now three new levels of MSN Hotmail Extra Storage! Learn more. http://join.msn.com/?pgmarket=en-us&page=hotmail/es2&ST=1