• 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: Running VPN client...
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Running VPN client...


  • Subject: Re: Running VPN client...
  • From: Christopher Nebel <email@hidden>
  • Date: Tue, 15 Jul 2003 15:47:33 -0700

On Tuesday, July 15, 2003, at 1:06 PM, Emmanuel wrote:

At 9:50 AM -0700 14/07/03, Christopher Nebel wrote:
This returns immediately, and spits "done" into /tmp/junk.junk 20 seconds later:

do shell script "(sleep 60; echo done) >/tmp/junk.junk 2>&1 &"

(you mean 60 I presume)

Yes, sorry. I was using 20 when testing it so I didn't have to wait so long. :-)

If I may, still another question. I see users of SmileLab[1] (people used to UNIX) that write:

do shell script "their_command >& file_path &"

(and it looks like it's returning immediately)

Is there any difference between the two syntaxes above?

No, there isn't -- ">& f" routes both stdout and stderr to the same place, which is what the first syntax does. In fact, the bash man page recommends that you use "&> f".

There is one caveat, though: as far as I can tell, ">&" and "&>" are not in the original sh -- it's something that's been added to later shells, including zsh and bash, which provide the sh support in Mac OS X. (zsh for Mac OS X 10.1 and earlier, bash for 10.2 and later.) So for Mac OS X, no problems. For an arbitrary Unix box, maybe.


--Chris Nebel
Apple Development Tools
_______________________________________________
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.

References: 
 >Re: Running VPN client... (From: Emmanuel <email@hidden>)

  • Prev by Date: Re: Dialog Director - Counting Characters
  • Next by Date: Re: getting multiple selected messages in Eudora?
  • Previous by thread: Re: Running VPN client...
  • Next by thread: Re: open location..
  • Index(es):
    • Date
    • Thread