• 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: Multicast Auto Start Applescript
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Multicast Auto Start Applescript


  • Subject: Re: Multicast Auto Start Applescript
  • From: Ian Ward Comfort <email@hidden>
  • Date: Thu, 10 Aug 2006 16:08:26 -0700

On Aug 10, 2006, at 3:42 PM, schragej wrote:
I need the “asr” command to output to something (terminal, a file, anything at all) so I can see the status of the command. The applescript developers page describing calling shell scripts falls short here....maybe someone can help me out?

Here is the script...it works fine right now, just cannot see what ASR is doing......

<snip>

do shell script "asr -source " & dmgPath & " -server /Volumes/ ServerHD/Applications/Utilities/Multicast/PreConfigPlists/ COCmulticast.plist -interface en0 &> /Volumes/ServerHD/Users/admin/ Desktop/asrlog 2>&1 & echo $!" user name userName password adminPass with administrator privileges
set pid to the result

First off note that &> and 2>&1 are redundant. &>file is equivalent to >file 2>&1, see `man bash`.


As for what you want to do with AppleScript, IIRC "do shell script" won't return until its entire process group has terminated, so backgrounding a task with & won't allow your script to continue executing. If you want to fire off the asr server and immediately return control to your script you'll probably have to write yourself e.g. a simple Perl script that daemonizes before starting asr, and call that from your AppleScript.

Also, don't forget that the options to `asr` changed around 10.4.6. (`asr server --source ...` and the like.)

—IWC

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Multicast Auto Start Applescript (From: schragej <email@hidden>)

  • Prev by Date: Multicast Auto Start Applescript
  • Next by Date: Re: INDESIGN CS2: Altering a Text Selection
  • Previous by thread: Multicast Auto Start Applescript
  • Next by thread: [ANN] Usable Keychain Scripting
  • Index(es):
    • Date
    • Thread