Thanks to df for pointing out that Apple has posted release notes for AppleScript in Leopard.We can now ask if an application is running, without AppleScript launching it to find out. ;-)Some nice additions to running AppleScript on the Command Line:
#to comment out a line
- start the script with
#!/usr/bin/osascript, and make it executable, will enable it to be run in the shell
osadecompileis a command line script to display compiled scripts as text
osascript also supports additional arguments on the command line, so now you can run a script and provide strings for it to use. see the osascript man page for details, and an example. This feature was available in Tiger, I just never noticed until now!