help please

i am trying to automate, both actions here. i am trying to open the terminal and then cd to a folder, and then do a command. also launch a app. but my problem is doing the terminal and then busting the command.

please help me, i am new. thanx

heres the code. it works great except for just one part::

launch application “Folding@home”
launch application “Terminal”
tell application “Terminal”
do script “cd ‘/Applications/CPU Projects/f@h/Unix Version/’”
[with command “./OSX-3.25 -local -verbosity 9”]
end tell

First the obvious question - why use at all.

You can execute shell commands via the standard ‘do shell script’ without launching The only reason to use would be if you needed to interact with the shell command in any way.

That said, if you want to string multiple shell commands together in one action, separate them with semi-colons:

tell application “Terminal”
do script “cd ‘/Applications/CPU Projects/f@h/Unix Version/’; ./OSX-3.25 -local -verbosity 9”
end tell

(which could also be simplified to:

do shell script “cd ‘/Applications/CPU Projects/f@h/Unix Version/’; ./OSX-3.25 -local -verbosity 9”

without the terminal at all.

Alternatively, if you are using the terminal, you can direct shell commands to a particular window:

tell application “terminal”
do script “cd ‘/Applications/CPU Projects/f@h/Unix Version/’” in window 1
do script “./OSX-3.25 -local -verbosity 9” in window 1
end tell

the [in window x] element tells where to run the command. In this case in the front window. Subsequent commands that target the same window will have the same effect as the semicolon-delimited example. However, this example cares little about what else may be going on in window 1 at the time, so use it with caution.

hey thanx a lot. it worked. all i need was a little help. the simicolon help. oh, i am using the terminal because i am loading the unix version. i use both, for dual cpu. is there a list of commands and objects for applescript, here on my computer?