SublimeLinter / SublimeLinter-rubocop

SublimeLinter 3 plugin for Ruby, using rubocop.
MIT License
159 stars 40 forks source link

Linter not ignoring directories listed in `.rubocop.yml`? #8

Closed kreeger closed 10 years ago

kreeger commented 10 years ago

I've got a .rubocop.yml file with this bit at the top:

AllCops:
  Exclude:
    - 'db/**/*'
    - 'config/**/*'
    - 'script/**/*'

But the plugin doesn't seem to be taking these exclusions into account. Is there a different way to exclude files and directories from being linted? Perhaps through SublimeLinter's settings itself?

kreeger commented 10 years ago

Welp, I should have searched the docs first — my solution is the latter.

{
    "...",
    "linters": {
        "rubocop": {
            "@disable": false,
            "args": [],
            "excludes": [
                "*/db/**/*",
                "*/config/**/*",
                "*/script/**/*"
            ]
        }
    }
}
aparajita commented 10 years ago

In addition to searching the documentation first, you should also search the issues first to see if what you are reporting has already been dealt with. In this case it was.

https://github.com/SublimeLinter/SublimeLinter-rubocop/issues/6