[prev] [thread] [next] [lurker] [Date index for 2006/05/30]
On 5/29/06, Dominic Mitchell <dom@xxxxxxxxxxxx.xxx> wrote: > JavaScript -- the new respectable face of the web. Until you want to do > anything with it outside of a browser. There's apparently lots of choice: > > * Rhino -- except that loading a full JVM to run a few lines of > JavaScript code is living using a JCB to swat a fly. > * SpiderMonkey -- Mozilla's JavaScript engine, ripped out and zombie-like. > * njs -- so dormant it's like Rip van Winkle. > * WSH -- yep, that'll work really well on my mac. > > All I wanted to do was run JSLint at the command line. Surely it can't > be that hard? Yet SpiderMonkey has no I/O capabilities at all. Rhino > has ReadFile(), but it's Java and slow. njs couldn't even parse the > bloody jslint source, let alone try providing some input to it. > > That's OK, I'll work around this by using JavaScript::SpiderMonkey and a > small bit of Perl. Except that appears to hang completely when run > against the simplest function(). What a steaming pile of donkey turds. A couple of alternatives for you: XPCShell is Spidermonkey with a command prompt and print() function http://www.mozilla.org/scriptable/XPCShell.html A different Spidermonkey module for Perl http://search.cpan.org/~claesjac/JavaScript-0.55/ -- Yoz
Generated at 08:01 on 31 May 2006 by mariachi 0.52