• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Responding to "scanf" in do shell script
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Responding to "scanf" in do shell script


  • Subject: Re: Responding to "scanf" in do shell script
  • From: "J. Stewart" <email@hidden>
  • Date: Mon, 31 May 2010 07:45:39 -0400

On 5/30/10 at 4:28 PM, André Renault <email@hidden> spake thusly:

How do I respond to a scanf command using do shell script? I prefer not to use Terminal, unless that's necessary.


If you are trying to interact with a UNIX shell without terminal then I'd suggest using "expect" <http://en.wikipedia.org/wiki/Expect>. It can give 'canned' responses in reply to shell queries but if you need live input that varies it won't help.

Last time I checked this wasn't included with a MacOS X install so you'd need to install it via MacPorts or Fink.

John
--
Never try to outstubborn a cat.  -Lazarus Long (Robert Heinlein)
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden
References: 
 >Responding to "scanf" in do shell script (From: André Renault <email@hidden>)

  • Prev by Date: Бухгалтерский учет на каждый день - Buhteach.ru
  • Next by Date: Fellow Applescripter
  • Previous by thread: Responding to "scanf" in do shell script
  • Next by thread: Бухгалтерский учет на каждый день - Buhteach.ru
  • Index(es):
    • Date
    • Thread