coffeelint icon indicating copy to clipboard operation
coffeelint copied to clipboard

Add a path entry to coffeelintConfig

Open adius opened this issue 8 years ago • 4 comments

A path entry should be available in coffeelint like

{
  "coffeelintConfig": {
    path: "./node_modules/coffeescipt-styleguide/coffeelint/coffeelint.json"
  }
}

It's really crappy that we have to copy and paste coffeelint files in every repostiory in times of npm modularization. I know it would be possible do to something like:

{
  "scripts": {
    "prepublish": "coffeelint -f ./node_modules/coffeescipt-styleguide/coffeelint.json app.coffee"
  }
}

The problem is that this is application specific and therefore editors and IDEs don't pick it up automatically.

adius avatar Jul 17 '15 23:07 adius

If someone wants to take the time to build this suggestion, it should be modeled after the way eslint lets you extend config files

AsaAyers avatar Jul 17 '15 23:07 AsaAyers

Yeah, that's a good idea!

adius avatar Jul 17 '15 23:07 adius

One of the problems with that solution: You would still need to install additional rules in the original project. Instead I'm using a wrapper for coffeelint with help of a small module I made.

Only thing that is a little ugly: Due to changed cwd the output of coffeelint shows incorrect paths.

dbartholomae avatar Jan 11 '16 04:01 dbartholomae

FYI, this seems to have been implemented in #478, so the following works (including with atom-linter):

"coffeelintConfig": {
  "extends": "node-module"
}

@adius ☝️

I think this is a duplicate of #461, but should probably be closed anyway. @clutchski @swang I wouldn't mind having push access on here if you're looking for help…

danielbayley avatar Sep 22 '17 18:09 danielbayley