Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!wuarchive!zaphod.mps.ohio-state.edu!lavaca.uh.edu!menudo.uh.edu!sugar!ficc!peter From: peter@ficc.ferranti.com (Peter da Silva) Newsgroups: comp.unix.shell Subject: Re: How do you pipe after a here document Message-ID: <1F37P47@xds13.ferranti.com> Date: 20 Nov 90 23:52:44 GMT References: <1990Nov8.201508.13222@cid.aes.doe.CA> <27620006@hp-lsd.COS.HP.COM> Reply-To: peter@ficc.ferranti.com (Peter da Silva) Organization: Xenix Support, FICC Lines: 21 In article <27620006@hp-lsd.COS.HP.COM> jimr@hp-lsd.COS.HP.COM (Jim Rogers) writes: > The following works for me: > > #! /bin/sh > cat < I,ve got > a lovely > bunch of coconuts > END 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 (nope, stranger, it's "this here document") -- Peter da Silva. `-_-' +1 713 274 5180. 'U` peter@ferranti.com