• 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: Passing variable from AppleScript to Terminal
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Passing variable from AppleScript to Terminal


  • Subject: Re: Passing variable from AppleScript to Terminal
  • From: garbanzito <email@hidden>
  • Date: Fri, 2 Nov 2001 13:27:30 -0700

at 2001 11 01, 15:36 +0000, they whom i call Laurence Wilks wrote:
tell application "Terminal"

do script with command "cd " & thepath & "; ls -l"

end tell

on convert_filepath(this_filepath)
[...]

check out this script on MacOSXHints for a more complete
path conversion script (it escapes special characters like spaces,
and handles volumes other than the boot volume).

<http://www.macosxhints.com/article.php?story=20011030193449870>

Hope this is a reasonably efficent way of doing this, anyone know a better way?

it's basically the only way (other than using *.command files). if
you don't want to create a Terminal window, use the "shell" command
from OSX Power Additions:

<http://osaxen.com/?id=aeshell>

--
steve harley email@hidden


  • Prev by Date: Re: Parsing HTML
  • Next by Date: Re: Memory allocation of applets?
  • Previous by thread: implementing unix strftime as an AS library - seeking advice
  • Next by thread: Newly bust in OSX: ":" as alias
  • Index(es):
    • Date
    • Thread