Xref: utzoo comp.sources.wanted:9400 alt.sources:1217 misc.wanted:6879
Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!wuarchive!brutus.cs.uiuc.edu!apple!oliveb!mipos3!ismdqa!tom
From: tom@ismdqa.intel.com (Tom Soukup ~)
Newsgroups: comp.sources.wanted,alt.sources,misc.wanted
Subject: Re: duplicate output to multiple terminals
Message-ID: <1235@mipos3.intel.com>
Date: 11 Nov 89 18:59:33 GMT
References: <256@telxon.UUCP> <4647@cbnewsc.ATT.COM>
Sender: news@mipos3.intel.com
Reply-To: tom@ismdqa.UUCP (Tom Soukup ~)
Organization: Microprocessor Component Group, Intel Corp., Santa Clara, CA
Lines: 25

In article <4647@cbnewsc.ATT.COM> psfales@cbnewsc.ATT.COM (Peter Fales) writes:
>In article <256@telxon.UUCP>, dank@telxon.UUCP (Dan Kelley) writes:
>> I am looking for an idea to duplicate output on different terminals.
>The "teacher" executes the following command:
>	cu XXXX	| tee /tmp/tmpfile
>The "students" run 
>	tail -f /tmp/tmpfile
>I don't totally understand why this works, but it does.  You can even
>see all the "teacher's" key strokes in real time.

This works because tail -f writes the contents of the file to the standard
output (the screen) and then waits.  As additional characters are put into
the file, tail -f continues writing them to the screen.  It will continue
waiting forever (I think) unless interupted.  So the cu | tee copies
everything that the cu echos into tmpfile and the tail prints everything
that goes into tmpfile on thr students screen.  Good idea, I wish I'd
thought of it :-).

>Peter Fales			AT&T, Room 5B-420

Tom
________________________________________________________________________________
DISCLAMER:  Intel doesn't agree with much of anything that I say.
UUCP:	{amdcad,decwrl,hplabs,oliveb,pur-ee,qantel}!intelca!mipos3!ismdqa!tom
ARPA:	tom%ismdqa.intel.com@relay.cs.net       CSNET:	tom@ismdqa.intel.com