• 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: Osascript timesaving tip
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Osascript timesaving tip


  • Subject: Re: Osascript timesaving tip
  • From: Steven Majewski <email@hidden>
  • Date: Tue, 4 May 2004 13:24:22 -0400

On May 4, 2004, at 5:35 AM, Martin Orpen wrote:

I've just posted a osascript tip to macosxhints - but thought I'd run it
past the group first to see what you think.

I got really fed up with having to use osascript -e when running
applescripts remotely via the Terminal.

So I thought that I'd give the redirect command a try - thus allowing me to
type and view the script in a way that is much easier to bugfix than a
single line.

So to run a remote script I now do:

$ cat << done | osascript

And on hitting enter I get a new prompt which allows me to enter the script
line-by-line and then finish with whatever word I choose to indicate that
the input has ended (in this case done).


You don't even need the 'cat <<done' .
Just type 'osascript' with no '-e' or filename, and it will read from STDIN.
End with a control-D (EOF)

(That'll save you a few more keystrokes.)

-- sdm
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.


  • Follow-Ups:
    • Re: Osascript timesaving tip
      • From: Martin Orpen <email@hidden>
References: 
 >Osascript timesaving tip (From: Martin Orpen <email@hidden>)

  • Prev by Date: Scripting FMP7
  • Next by Date: A script that might be useful to some
  • Previous by thread: Re: Osascript timesaving tip
  • Next by thread: Re: Osascript timesaving tip
  • Index(es):
    • Date
    • Thread