JavaScript interpreter in Dashboard
The JavaScript shell is nice, but if you’re using OS X there’s a better option. On a tip from Todd Ditchendorf, I’m now running both a JavaScript and a Ruby interpreter in Dashboard, just a keystroke away.
It’s easy. Todd gives directions for installing WidgetTerm, which is key to the whole thing. Then drop a jar from the Rhino project in your Java classpath, set an alias to a JavaScript shell, fire up a WidgetTerm instance, and you’re done. It sounds more complicated than it is.
I need to pay more attention to Rhino. It caught my attention when I read this discussion of choosing a Java scripting language and saw how Rhino stacked up against JRuby, Groovy, Jython, and others. Here’s an obvious application.
20 Mar 2006 Sam