I'm not sure how much interest there is for this, but I have wrapped
Douglas Crockford's JSLint as a CommonJS module and wrote a simple
front-end for it using Narwhal's command line argument parser. I know
there is some prior art with respect to command line JSLint front-
ends, but I really needed something that could read from both files
and stdin. I have released the JSLint module and front-end as separate
packages so it is possible to 'require' the JSLint module without my
front-end.
You can install both of them with Tusk:
tusk install http://github.com/bramstein/fulljslint/zipball/master
tusk install http://github.com/bramstein/jslint/zipball/master
If the installation was successful you can run "jslint --help" to get
an overview of the available options. More documentation and source
code is available on my Github page (http://github.com/bramstein/
jslint).
I encountered a small problem while installing remote packages; Tusk
tries to write the package to a temporary directory in the "zips"
subdirectory of the Narwhal home directory. This directory does not
exist by default. Simply creating it fixes the problem. Perhaps Tusk
should create the directory if it doesn't exist.
Thanks,
Bram Stein
Awesome, it works for me. I can get it added to the tusk catalog if
jslint explicates that it's dependent on fulljslint:
http://github.com/kriskowal/jslint/commit/e467c582fe58be29f728214a915ea5fee689fde9
This will make the following work:
$ tusk update
$ tusk install jslint
I think it would be good to rename fulljslint to jslint-core or
something, so that they stand side by side in lexical order, or jslint
and jslint-command. A name change is not required for my help in
getting it in the catalog though. Thanks!
Kris Kowal
Added to source.json and rebuilt the catalog. Merge-ready:
http://github.com/kriskowal/narwhal/commit/b85eeb3a6cbea2be880dd2a0758e91dde10b0312
Kris Kowal