Loading ...
Sorry, an error occurred while loading the content.
 

Re: [jslint] JSLint in Unix

Expand Messages
  • Michael Mikowski
    As an alternative, this shell script works nicely if you have Java installed.  It uses the jslint4java release from http://code.google.com/p/jslint4java/
    Message 1 of 7 , Mar 17, 2013
      As an alternative, this shell script works nicely if you have Java installed.  It uses the jslint4java release from http://code.google.com/p/jslint4java/ which uses Rhino.  You can replace the path  (/usr/local/lib/jslint4java-2.0.2/jslint4java-2.0.2.jar)
      with the path to the jslint4java jar you have downloaded.  I found its performance to be quite reasonable, although I expect the node.js implementation should be faster.

      =======================
      #!/bin/bash

      # See http://code.google.com/p/jslint4java/%c2%a0

      for jsfile in $@; 
        do /usr/bin/java \
          -jar /usr/local/lib/jslint4java-2.0.2/jslint4java-2.0.2.jar \
          "$jsfile";
      done



      ________________________________
      From: argillaceousvis <visaudi@...>
      To: jslint_com@yahoogroups.com
      Sent: Saturday, March 16, 2013 1:55 PM
      Subject: Re: [jslint] JSLint in Unix


       
      Dylon,

      This is great!

      Thank you so much!

      --- In jslint_com@yahoogroups.com, Dylon Edwards <integr8e@...> wrote:
      >
      > I maintain a fork of jslint-utils, that uses Node.js (I haven't been
      > maintaining the Rhino scripts). It may be of use to you:
      > https://github.com/dylon/jslint-utils
      >
      > Dylon
      >
      >
      > On Sat, Mar 16, 2013 at 1:04 PM, argillaceousvis <visaudi@...> wrote:
      >
      > > **
      > >
      > >
      > > I saw that a while ago someone had made a Unix JSLint Wrapper.
      > >
      > > It looks like it hasn't been updated for quite some time.
      > >
      > > Anyone know of any projects that do this?
      > >
      > >
      > >
      >
      >
      > [Non-text portions of this message have been removed]
      >




      [Non-text portions of this message have been removed]
    • Dominic Mitchell
      ... You should be able to reduce this to: #/bin/bash /usr/bin/java -jar /usr/local/lib/jslint4java-2.0.2/jslint4java-2.0.2.jar $@ -Dom ... [Non-text portions
      Message 2 of 7 , Mar 17, 2013
        On Sun, Mar 17, 2013 at 4:33 PM, Michael Mikowski <z_mikowski@...>wrote:

        > As an alternative, this shell script works nicely if you have Java
        > installed. It uses the jslint4java release from
        > http://code.google.com/p/jslint4java/ which uses Rhino. You can replace
        > the path (/usr/local/lib/jslint4java-2.0.2/jslint4java-2.0.2.jar)
        > with the path to the jslint4java jar you have downloaded. I found its
        > performance to be quite reasonable, although I expect the node.js
        > implementation should be faster.
        >
        > =======================
        > #!/bin/bash
        >
        > # See http://code.google.com/p/jslint4java/
        >
        > for jsfile in $@;
        > do /usr/bin/java \
        > -jar /usr/local/lib/jslint4java-2.0.2/jslint4java-2.0.2.jar \
        > "$jsfile";
        > done
        >

        You should be able to reduce this to:

        #/bin/bash
        /usr/bin/java -jar /usr/local/lib/jslint4java-2.0.2/jslint4java-2.0.2.jar
        "$@"


        -Dom


        >
        >
        >
        > ________________________________
        > From: argillaceousvis <visaudi@...>
        > To: jslint_com@yahoogroups.com
        > Sent: Saturday, March 16, 2013 1:55 PM
        > Subject: Re: [jslint] JSLint in Unix
        >
        >
        >
        > Dylon,
        >
        > This is great!
        >
        > Thank you so much!
        >
        > --- In jslint_com@yahoogroups.com, Dylon Edwards <integr8e@...> wrote:
        > >
        > > I maintain a fork of jslint-utils, that uses Node.js (I haven't been
        > > maintaining the Rhino scripts). It may be of use to you:
        > > https://github.com/dylon/jslint-utils
        > >
        > > Dylon
        > >
        > >
        > > On Sat, Mar 16, 2013 at 1:04 PM, argillaceousvis <visaudi@...> wrote:
        > >
        > > > **
        > > >
        > > >
        > > > I saw that a while ago someone had made a Unix JSLint Wrapper.
        > > >
        > > > It looks like it hasn't been updated for quite some time.
        > > >
        > > > Anyone know of any projects that do this?
        > > >
        > > >
        > > >
        > >
        > >
        > > [Non-text portions of this message have been removed]
        > >
        >
        >
        >
        >
        > [Non-text portions of this message have been removed]
        >
        >
        >
        > ------------------------------------
        >
        > Yahoo! Groups Links
        >
        >
        >
        >


        [Non-text portions of this message have been removed]
      • argillaceousvis
        Thank you both. It s good to have options. I ll probably go with node, but it s really just nice to have a JSLint I can run between Git and Vim. I really
        Message 3 of 7 , Mar 17, 2013
          Thank you both.

          It's good to have options. I'll probably go with node, but it's really just nice to have a JSLint I can run between Git and Vim.

          I really appreciate everyone's help and friendliness.

          -Ben

          --- In jslint_com@yahoogroups.com, Dominic Mitchell <dom@...> wrote:
          >
          > On Sun, Mar 17, 2013 at 4:33 PM, Michael Mikowski <z_mikowski@...>wrote:
          >
          > > As an alternative, this shell script works nicely if you have Java
          > > installed. It uses the jslint4java release from
          > > http://code.google.com/p/jslint4java/ which uses Rhino. You can replace
          > > the path (/usr/local/lib/jslint4java-2.0.2/jslint4java-2.0.2.jar)
          > > with the path to the jslint4java jar you have downloaded. I found its
          > > performance to be quite reasonable, although I expect the node.js
          > > implementation should be faster.
          > >
          > > =======================
          > > #!/bin/bash
          > >
          > > # See http://code.google.com/p/jslint4java/
          > >
          > > for jsfile in $@;
          > > do /usr/bin/java \
          > > -jar /usr/local/lib/jslint4java-2.0.2/jslint4java-2.0.2.jar \
          > > "$jsfile";
          > > done
          > >
          >
          > You should be able to reduce this to:
          >
          > #/bin/bash
          > /usr/bin/java -jar /usr/local/lib/jslint4java-2.0.2/jslint4java-2.0.2.jar
          > "$@"
          >
          >
          > -Dom
          >
          >
          > >
          > >
          > >
          > > ________________________________
          > > From: argillaceousvis <visaudi@...>
          > > To: jslint_com@yahoogroups.com
          > > Sent: Saturday, March 16, 2013 1:55 PM
          > > Subject: Re: [jslint] JSLint in Unix
          > >
          > >
          > >
          > > Dylon,
          > >
          > > This is great!
          > >
          > > Thank you so much!
          > >
          > > --- In jslint_com@yahoogroups.com, Dylon Edwards <integr8e@> wrote:
          > > >
          > > > I maintain a fork of jslint-utils, that uses Node.js (I haven't been
          > > > maintaining the Rhino scripts). It may be of use to you:
          > > > https://github.com/dylon/jslint-utils
          > > >
          > > > Dylon
          > > >
          > > >
          > > > On Sat, Mar 16, 2013 at 1:04 PM, argillaceousvis <visaudi@> wrote:
          > > >
          > > > > **
          > > > >
          > > > >
          > > > > I saw that a while ago someone had made a Unix JSLint Wrapper.
          > > > >
          > > > > It looks like it hasn't been updated for quite some time.
          > > > >
          > > > > Anyone know of any projects that do this?
          > > > >
          > > > >
          > > > >
          > > >
          > > >
          > > > [Non-text portions of this message have been removed]
          > > >
          > >
          > >
          > >
          > >
          > > [Non-text portions of this message have been removed]
          > >
          > >
          > >
          > > ------------------------------------
          > >
          > > Yahoo! Groups Links
          > >
          > >
          > >
          > >
          >
          >
          > [Non-text portions of this message have been removed]
          >
        • Frederik Dohr
          ... FWIW, that s what I wrote JSLint Reporter for: https://github.com/FND/jslint-reporter (I wasn t aware of the JSLint Utils until now) I ve added both
          Message 4 of 7 , Mar 18, 2013
            > have a JSLint I can run between Git and Vim

            FWIW, that's what I wrote JSLint Reporter for:
            https://github.com/FND/jslint-reporter
            (I wasn't aware of the JSLint Utils until now)

            I've added both projects to the wiki:
            https://github.com/douglascrockford/JSLint/wiki/JSLINT


            -- F.
          Your message has been successfully submitted and would be delivered to recipients shortly.