Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/18/84; site turtlevax.UUCP Path: utzoo!watmath!clyde!burl!ulysses!allegra!bellcore!decvax!decwrl!turtlevax!ken From: ken@turtlevax.UUCP (Ken Turkowski) Newsgroups: net.unix-wizards Subject: Shell scripts waiting for foreground Message-ID: <737@turtlevax.UUCP> Date: Tue, 16-Apr-85 15:30:36 EST Article-I.D.: turtleva.737 Posted: Tue Apr 16 15:30:36 1985 Date-Received: Thu, 18-Apr-85 04:41:53 EST Reply-To: ken@turtlevax.UUCP (Ken Turkowski) Organization: CADLINC, Inc. @ Menlo Park, CA Lines: 13 I would like to write a shell script that dumps its standard input to a file, then cats the file when the end-of-input has been found. It will do this as long as the program is running in the foreground. If in the background, it will print out a short message, then wait to come to the foreground before it prints the file. Can this be done with either sh or csh? Or do I need to write a C program? I am running 4.2bsd. -- Ken Turkowski @ CADLINC, Menlo Park, CA UUCP: {amd,decwrl,hplabs,nsc,seismo,spar}!turtlevax!ken ARPA: turtlevax!ken@DECWRL.ARPA