[openstack-dev] [javascript] Linters

Michael Krotscheck krotscheck at gmail.com
Mon Jun 8 15:48:20 UTC 2015


On Mon, Jun 8, 2015 at 1:59 AM Matthias Runge <mrunge at redhat.com> wrote:

>
> jshint: still non-free license [1]
>

Yep! Ergo, we can't really use it.


> eslint seems to require to sign a CLA, if we come across an issue and
> were going to fix that.
>

So does the python foundation, I'm not really worried about it.


> jscs seems to be the utility, cool kids are using. As expected, it
> requires node. It has seen 3 releases within 3 months, or 5 in 4 months.
>

Google trends disagrees with this assertion:
https://www.google.com/trends/explore#q=eslint%2C%20jscs%2C%20jshint%2C%20jslint&cmpt=q&tz=

Also, as a random aside, I have read things On The Internet (tm) that say
that eslint is better about doing PMD things like scope variable overrides
and unused parameters. Not having used JSCS, I can't really comment.

My question here would be: how are we going to handle changes here over a
> release (and how to keep this running on the gate for released
> versions)?
> <http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev>
>

The required version of eslint is actually defined per project, in
package.json. As long as the project does NOT use fuzzy version matching
(~1.x.x), the build should remain reliable.

Furthermore, all 'lint' builds are abstracted behind the `npm run lint`
command, and is definable by project, so specific changes to the linting
configuration are committed to the codebase. Here's an example:
https://review.openstack.org/#/c/185711/5/refstack-ui/package.json

Michael
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack-dev/attachments/20150608/8a8a272a/attachment.html>


More information about the OpenStack-dev mailing list