gilbarbara / codeclimate-stylelint

A Code Climate engine for the mighty, modern CSS linter
24 stars 18 forks source link

Can't lint sass files #22

Closed johndrwood closed 5 years ago

johndrwood commented 6 years ago

I can't seem to get the codeclimate stylelint plugin to lint .sass files. It works fine when running the stylelint CLI but not in the codeclimate CLI.

My .stylelintrc is as follows:

{
  "rules": {
    "declaration-property-value-blacklist": {
      "border": ["none"]
    }
  }
}

.codeclimate.yml is as follows:

version: "2"
plugins:
  stylelint:
    enabled: true

When running:

some_path% codeclimate analyze

The output is:

Starting analysis
Running structure: Done!
Running duplication: Done!
Running stylelint: Done!

== print.css (1 issue) ==
13: Unexpected value "none" for property "border" (declaration-property-value-blacklist) [stylelint]

Analysis complete! Found 1 issue.

But when I run:

some_path% stylelint .

The output is:

admin-tables.sass
 2:3  ✖  Unexpected value "none" for property "border"   declaration-property-value-blacklist

print.css
 13:37  ✖  Unexpected value "none" for property "border"   declaration-property-value-blacklist

Any guidance on how to get codeclimate to lint .sass files?

johndrwood commented 6 years ago

Not sure if it's as simple as adding .sass here?

https://github.com/gilbarbara/codeclimate-stylelint/blob/48906fbe7134acb1c2bf6ebe444658ad48975583/bin/codeclimate-stylelint.js#L9

gilbarbara commented 5 years ago

Added in 2.2.0