ricardofbarros / linter-js-standard

Atom linter plugin for JavaScript, using JavaScript Standard Style
https://atom.io/packages/linter-js-standard
MIT License
99 stars 48 forks source link

Disable/enable per project to avoid clashing with other linters #79

Closed laander closed 8 years ago

laander commented 8 years ago

As per this discussion https://github.com/atom-community/linter/issues/682 I'm having some major headaches switching between projects where some use standard and others use eslint, jshint etc.

While linter-eslint, linter-jshint and linter-jscs have settings to enable the linters only when they encounter their respect .rc files. Standard doesn't have any .rc file so how do we solve this?

I would love a universal standard for setting a preferred linter for JS project, in e.g. package.json (think a "lint" key) or equivalent. That's perhaps a bit ambitious in the short run, so in the short run, I'd propose the following:

An atom setting named ~enableOnlyOnPackageKey where, if true, the linter should only be enabled if there's a "standard" key found in package.json (no matter it's content). It should default to false. Other ideas?

wyze commented 8 years ago

You should already be able to do this. There is an option Check for standard which defaults to false.

See here.

laander commented 8 years ago

Ah, perfect. Thanks a lot :+1: