I Have a Dream
If I had my way, I would never leave my Smalltalk image.
It’s not just the Smalltalk language (although I do enjoy the Zen-like minimal syntax, and keyword arguments flow off the keyboard like conversational speech). The real gold is the live, open environment, and control over everything in my system, almost down to the metal.
Reality Sets In (but it’s not so bad this time)
Yet sometimes, for a quick and dirty throwaway script, a tool symbolizing poor design is perfect.
For example, I wanted to change the artist info of a batch of tracks in iTunes. In less? time than it would have taken me to google a solution, I had whipped up an AppleScript (yes, ouch) in AppleScript Editor (double ouch):
tell application "iTunes" set wrongName to "" set rightName to "" set track_list to tracks of playlist "Music" of source "Library" whose artist is wrongName repeat with t in track_list set artist of t to rightName end repeat end tell
Yes, I could have used rb-appscript to script from Ruby, which I usually do. But, AE gave me easy access to iTunes’ scripting dictionary, a nice little “Run” button, and an output pane. For this tiny script, I was done before I started to suffocate from being outside the oxygen of my live, open Smalltalk image.
So, thank you Apple, for creating the infuriating AppleScript language, to be written with the puny AppleScript Editor, and for not even making many of your own applications scriptable ([cough] Preview.app) even while evangelizing scriptability to Mac devs in your docs. Today, I was grateful for it all. Editing info on hundreds of tracks was much quicker than writing this post about it