home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.unix.questions
- Path: sparky!uunet!elroy.jpl.nasa.gov!orchard.la.locus.com!prodnet.la.locus.com!locus.com!mjl
- From: mjl@bos.locus.com (Mike Leibensperger)
- Subject: Re: How to handle data from stdin in a sh script
- In-Reply-To: klaus@helsinkiesf.de's message of 5 Nov 92 11: 23:17 GMT
- Message-ID: <MJL.92Nov5161719@rigel.bos.locus.com>
- Sender: news@locus.com (Netnews)
- Organization: Locus Computing Corp., Boston Massachusetts USA.
- References: <5725@esf.esf.de>
- Date: Thu, 5 Nov 1992 21:17:19 GMT
- Lines: 20
-
-
- In article <5725@esf.esf.de> klaus@helsinkiesf.de (Klaus Wicovsky) writes:
-
- Here is the problem: I would like to pipe data into a sh script and
- still be able to interact with the sh script (ask questions to the user).
-
- Use /dev/tty when interacting with the terminal:
-
- echo -n "Please confirm:" > /dev/tty
- read conf < /dev/tty
-
- Have a blast, viel Glueck, usw...
-
- mjl
- --
- Michael J. Leibensperger "Rats and roaches live by competition under the
- Locus Computing/Boston laws of supply and demand; it is the privilege
- 25 Mall Road; Burlington MA of human beings to live under the laws of
- 01803 (617)229-4980 mjl@locus.com justice and mercy." -- Wendell Berry
- Member of the League for Programming Freedom --- write league@prep.ai.mit.edu
-