From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <13426df10705150908y225a0a47l1d70c36b0ad5ec14@mail.gmail.com> Date: Tue, 15 May 2007 09:08:37 -0700 From: "ron minnich" To: "Fans of the OS Plan 9 from Bell Labs" <9fans@cse.psu.edu> Subject: Re: [9fans] A simple rc question In-Reply-To: <2ddf08d5378a0085dbf48bd98d52c3f9@coraid.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <13426df10705150838y7148f207m8fbc1631752fc8aa@mail.gmail.com> <2ddf08d5378a0085dbf48bd98d52c3f9@coraid.com> Topicbox-Message-UUID: 674d2582-ead2-11e9-9d60-3106f5b1d025 On 5/15/07, erik quanstrom wrote: > i think you have backgrounded the awk, but not the tail. > i think what you want is > > for(f){ > {tail -f $f | awk '{print "'^$f^':" $0}'}&} > } > > it sure looks like there are excessive {}s, but i think they are necessary. > otherwise & will bind to either awk or the for. I suspected that and will try it, but the man page is pretty clear (I thought) that a|b is a single command. I still think the & should bind to the pipeline, but ... ron