Path: utzoo!utgpu!news-server.csri.toronto.edu!rutgers!att!tut.cis.ohio-state.edu!VAX1.CC.UAKRON.EDU!mcs.kent.edu!usenet.ins.cwru.edu!ncoast!allbery From: allbery@NCoast.ORG (Brandon S. Allbery KB8JRR) Newsgroups: comp.unix.shell Subject: Re: Prompting for yes/no in csh Message-ID: <1991Jan11.041048.19034@NCoast.ORG> Date: 11 Jan 91 04:10:48 GMT References: <3821@ns-mx.uiowa.edu> <1660@inews.intel.com> Reply-To: allbery@ncoast.ORG (Brandon S. Allbery KB8JRR) Followup-To: comp.unix.shell Distribution: usa Organization: North Coast Computer Resources (ncoast) Lines: 25 As quoted from <1660@inews.intel.com> by bhoughto@hopi.intel.com (Blair P. Houghton): +--------------- | In article <3821@ns-mx.uiowa.edu> dkeber@umaxc.weeg.uiowa.edu (Dave Keber) writes: | >What is the easiest way to prompt for a yes/no (or any string/number, etc.) | >from a csh shell script? | | echo -n "continue? " | set foo=$< | | RTFM for csh(1) and echo(1). You could have learned all of +--------------- The ancient csh's supplied as value-added by most System V vendors do not have $< --- the manual csh(1) won't help here. But there is usually a "line" command that can be used similarly: echo "continue? \c" set foo="`line`" ++Brandon -- Me: Brandon S. Allbery VHF/UHF: KB8JRR on 220, 2m, 440 Internet: allbery@NCoast.ORG Packet: KB8JRR @ WA8BXN America OnLine: KB8JRR AMPR: KB8JRR.AmPR.ORG [44.70.4.88] uunet!usenet.ins.cwru.edu!ncoast!allbery Delphi: ALLBERY