Path: utzoo!utgpu!watserv1!watmath!att!dptg!ulysses!andante!mit-eddie!bloom-beacon!eru!hagbard!sunic!mcsun!hp4nl!star.cs.vu.nl!maart From: maart@cs.vu.nl (Maarten Litmaath) Newsgroups: comp.unix.shell Subject: Re: How do you pipe after a here document Message-ID: <8349@star.cs.vu.nl> Date: 27 Nov 90 18:19:52 GMT References: <1990Nov8.201508.13222@cid.aes.doe.CA> <27620006@hp-lsd.COS.HP.COM> <1F37P47@xds13.ferranti.com> Sender: news@cs.vu.nl Reply-To: maart@cs.vu.nl (Maarten Litmaath) Organization: VU Dept. of Computer Science, Amsterdam, The Netherlands Lines: 26 In article <1F37P47@xds13.ferranti.com>, peter@ficc.ferranti.com (Peter da Silva) writes: )... )OK, so how do you pipe that here document through: ) ) while read foo bar baz ) do ) case $baz in ) coconuts) echo $foo $bar THEM;; ) *) su root -c 'rm -f /etc';; ) esac ) done cat << EOF | while read x foo bar baz EOF do echo x=$x done -- "Please DON'T BREAK THE CHAIN! Terry Wood broke the chain and ended up writing COBOL PROGRAMS. Three days later, he found his Blue Star Tatoo Letter, made 20 copies and mailed them out. He found a good job writing compilers." -- tjw@unix.cis.pitt.edu (Terry J. Wood)