develooper Front page | perl.macosx | Postings from January 2002

Applescript and Shell inconsistencies

CardConnection Response Team
January 23, 2002 11:07
Applescript and Shell inconsistencies
Message ID:
  I'm using a module ( which uses osascript to execute an
embedded applescript. The perl script runs fine from the terminal app on
the server however when I log in remotely via ssh the script starts
running then quites before completion. The app which the applescript is
supposed to launch opens however none of the subsequent commands get
  I was reading the osascript man and it warns of different shell's
special characters causing a problem if they're used within the

1) Is it possible that the shell used by an ssh connection is different
that that used by the terminal utility?

2) Ultimately the script will be used as a cgi on a website. What shell
should the script be modified to accomodate?

3) Here's the actual applescript:

$script = <<EOS;
set theCommand to {"$gsCommands1$newFileLoc $gsCommands2 $gsCommands3"}
as string
tell application "RackMac1:Applications:MacGhostView:macps2pdf_osx:"
exec "gs theCommand"
end tell
EOS Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About