reid / node-jslint

The JavaScript Code Quality Tool — for Node.js.
http://jslint.com/
Other
491 stars 101 forks source link

Feature request: .jslintignore #122

Closed mcandre closed 9 years ago

mcandre commented 9 years ago

As a programmer, I want jslint to read gitignore-style patterns in per-directory / per-project / per-user locations, so that jslint <file|directory> skips over files I don't want it to check.

JSHint does this with .jshintignore files.

As a workaround, I can write a custom Unix find command:

find . -type d -name node_modules -prune -o -type d -name bower_components -prune -o -type f -name '*[-.]min.js' -prune -o -type f -name '*.js' -exec node_modules/jslint/bin/jslint.js {} \;

But I would prefer not to have to do this each time.

smikes commented 9 years ago

On reflection, I am going to say "no" to this and also to the recursive-descent operation (#110). My reasons are selfish: there are already many ways to get this functionality (find, grunt, broccoli) of producing a list of files and filtering out undesired files. In the recent past I've spent some effort on making node-jslint play better with other tools (the API, the stream interface), and there are plugins for grunt and broccoli that allow you to apply jslint to your js files while taking advantage of those tools' search/filter operations.

I only budget a small amount of time to maintain this project, and especially with the new editions of jslint coming out, I am going to have to save that time for making sure that we're shipping an up-to-date and correct version of jslint.

Thank you for making this feature request.