January 1, 2010 at 4:45 PM by Dr. Drang
Daniel Jalkut of Red Sweater Software recently released Version 2.5 of FastScripts, the utility that lets you run any kind of script (AppleScript, Perl, Python, Bash, etc.) from either a menu or a keyboard shortcut from any application. It’s mostly a bugfix release, but it does have a couple of worthwhile new features. If you’ve been reading this blog for any length of time, you know that I use FastScripts a lot, even though Snow Leopard’s new Services system is similar.
The only functionality added to FastScripts in Version 2.5 is the ability to run AppleScripts saved as plain text files (with an
.applescript extension). I’ve never saved AppleScripts in that format, mainly because I’m used to writing AppleScripts in the AppleScript Editor (née Script Editor), which saves in the script format (
.scpt extension) by default. But TextMate has an AppleScript bundle (described in a couple of screencasts) that might be worth trying out. That would consolidate all my scripting into TextMate and would lead to plain text AppleScripts.
FastScripts’ primary visual improvement is the ability to choose the color of its menu icon. Apparently, Daniel added this feature under duress from his users; he ascribes to Henry Ford’s philosophy. I prefer a bit of color to distinguish the items on the right side of the menubar, but I haven’t found a color that works with the FastScripts icon.
One bug not fixed in this release is a display problem with certain keyboard shortcuts. I have my SuspendSleep script bound to ⌃⌥⌘F19, which shows up in the FastScripts preferences like this
even though my F19 key doesn’t have a Chinese character on it. Maybe that’ll get fixed in the next release.
Before Snow Leopard, Mac people often complained that Services, available through a submenu under every application’s menu, were a great idea with a poor implementation. With Snow Leopard, many of these same people think Apple finally got it right. Not me—I still prefer FastScripts.
It’s true that Services has taken a big step forward, and it’s also true that Services and FastScripts don’t cover exactly the same ground. But there is a lot of overlap between the two, and in that overlap FastScripts is much better.
First, FastScripts runs scripts directly, whereas in Services you have to wrap your scripts in Automator actions, which has four detrimental effects:
- It adds an unnecessary level of complexity. You have to write the script correctly, and you have to fit the script within the Automator framework.
- It makes the command run slower. In my experience, at least, Automator actions always run slower than bare scripts.
- It screws up the debugging. When something goes wrong, is it the script or is it the way the script is called in Automator?
- If you also want the script to run from the command line (and I usually do), you need two versions: a regular script in your
$PATHfor the command line and an Automator action for Services. In contrasts, by soft linking (
ln -s) or extending your
$PATH, you can write one script used in FastScripts and at the command line.
A second, albeit minor, advantage of FastScripts is that you can assign keyboard shortcuts within FastScripts itself. No need to open up the Keyboard Preference Pane.
Finally, I just find FastScripts to be more Unix-y.1 I write a script using whatever tools I’m comfortable with, I save it in a particular directory, and it’s immediately available from the FastScripts menu. (Depending on which directory I save it in, it may be a script I can access from anywhere, or it may be a script that’s available only when I’m in a certain application.) It’s very much like scripting for the command line.
When Snow Leopard arrived, I was afraid Daniel would abandon FastScripts, seeing the new Services—built in and free—as an unbeatable competitor. I’m glad to see he’s still working on it, and I hope he keeps a big enough customer base to stay with it.
I consider that a good thing. Unix is a great environment for scripting. ↩