top bar
QuickTopic free message boards logo
Skip to Messages

TOPIC:

aslauncher

7
Matt McIrvin
11-08-2002
08:16 PM ET (US)
Hmm, forgot to mention that that script was tailored to a Fink installation. The PATH part you need is probably different if you installed the GhostScript that comes with GIMP-Print.
6
Matt McIrvin
11-08-2002
08:12 PM ET (US)
Until recently, I hadn't done much with AppleScript for several years. (The original reason I messed with it was that in System 7.x days, I didn't have a launcher/dock/control mechanism that I really liked, so I used speech recognition to control many things, which required writing little AppleScripts to do anything nontrivial. It was clumsy but futuristic.)

OS X has actually gotten me interested in AppleScript again, just because the Unix shell integration makes it possible to activate a Unix application or command via an AppleScript droplet that can take dropped file arguments. This in turn allows all manner of Unix/Mac integration, such as the ability to activate GIMP as an opener for picture files.

My latest trick was to use the ps2pdf command-line utility installed as part of GhostScript as a means of viewing PostScript language files with Preview or Acrobat Reader (whichever is your default viewer for PDFs):

on open input_file
 do shell script "export PATH=\"$PATH\":/sw/bin;ps2pdf \"" & POSIX path of input_file & "\" ~/.psview.tmp.pdf; open ~/.psview.tmp.pdf"
end open

If you've got GhostScript, you can save this as an application in Script Editor, use it as the opener for .ps files, and then PostScript becomes double-clickable.
5
MrHappyPerson was signed in when posted
11-07-2002
12:42 AM ET (US)
A scripter: works like a charm, thanks!
4
pbx
11-05-2002
04:51 PM ET (US)
You could also use "do shell script" inside your Applescript.
3
A scripter
11-05-2002
04:38 PM ET (US)
The script is waiting for feedback from each command before proceeding to the next command. Does this give you the concurrent behavior that you desire?

on run
ignoring application responses
tell application "Microsoft Entourage" to run
tell application "Mail" to run
tell application "Internet Explorer" to run
end ignoring
end run
2
A scripter
11-05-2002
04:37 PM ET (US)
The script is waiting for feedback from each command before proceeding to the next command. Does this give you the concurrent behavior that you desire?

on run
<br>ignoring application responses
<br>tell application "Microsoft Entourage" to run
<br>tell application "Mail" to run
<br>tell application "Internet Explorer" to run
<br>end ignoring
<br>end run

Print | RSS Views: 1003 (Unique: 664 ) / Subscribers: 0 | What's this?