Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!uflorida!gatech!emory!arnold From: arnold@mathcs.emory.edu (Arnold D. Robbins {EUCC}) Newsgroups: comp.unix.questions Subject: Re: sed/awk question Keywords: sed awk Message-ID: <4070@emory.mathcs.emory.edu> Date: 25 May 89 21:54:48 GMT References: <1049@necis.UUCP> Reply-To: arnold@emory.UUCP (Arnold D. Robbins {EUCC}) Distribution: usa Organization: Emory University Lines: 14 In article <1049@necis.UUCP> dhm@necis.UUCP (Dave Mitchell) writes: >Using sed or >awk, I want to print the lines of a file (from line 1) up to the first >occurrence of a dollar sign. Thanks for the help. awk '/\$/ { exit } { print }' That's all there is to it. -- Arnold Robbins -- Emory University Computing Center | Unix is a Registered DOMAIN: arnold@unix.cc.emory.edu | Bell of AT&T Trademark UUCP: gatech!emoryu1!arnold PHONE: +1 404 727-7636 | Laboratories. BITNET: arnold@emoryu1 FAX: +1 404 727-2599 | -- Donn Seeley