JavaScript Shell Command from JDK
This tutorial provides introductions and examples on the JavaScript shell command included in the JDK package. Topics include downloading and installing JDK 1.6, ECMAScript engine, running JavaScript code in command line, interactive or batch mode.
Read more here
edit: Programming/Javascript/auto___javascript_shell_command_from_jdk.wikieditish...