Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ESLint 5.1.0 - No files matching the pattern for several repos #10599

Closed
gnobre opened this issue Jul 12, 2018 · 4 comments
Closed

ESLint 5.1.0 - No files matching the pattern for several repos #10599

gnobre opened this issue Jul 12, 2018 · 4 comments
Labels
archived due to age This issue has been archived; please open a new issue for any further discussion triage An ESLint team member will look at this issue soon

Comments

@gnobre
Copy link

gnobre commented Jul 12, 2018

  • ESLint Version: 5.1.0
  • Node Version: v8.10.0
  • npm Version: 6.1.0
Configuration
{
    "parserOptions": {
        "ecmaVersion": 6,
        "sourceType": "module",
        "ecmaFeatures": {
            "jsx": true
        }
    },
    "rules": {
        "indent": [
            2,
            4,
            {"SwitchCase": 1}
        ],
        "quotes": [
            2,
            "double"
        ],
        "linebreak-style": [
            2,
            "unix"
        ],
        "semi": [
            2,
            "always"
        ],
        "dot-notation": 0,
        "camelcase": 0,
        "strict": 0,
        "no-var": 2,
        "prefer-const": 2,
        "prefer-rest-params": 2,
        "no-unreachable": 2,
        "eol-last": 2,
        "key-spacing": [2, {"beforeColon": false, "afterColon": true}],
        "keyword-spacing": [2, {
            "before": true,
            "after": true
        }],
        "no-multiple-empty-lines": [2, {"max": 2, "maxEOF": 1}],
        "no-trailing-spaces": 2,
        "eqeqeq": 2,
        "no-console": 0,
        "no-alert": 1,
        "complexity": [0, 11],
        "space-before-function-paren": 2,
        "comma-spacing": [2, {"before": false, "after": true}]
    },
    "env": {
        "es6": true,
        "node": true,
        "browser": true
    },
    "extends": "eslint:recommended"
}

What did you do?

eslint **/*.js

What did you expect to happen?
ESLint would run fine as previous versions. No code was changed for this repo since the lat time I ran eslint, suddenly stopped working after ESLint update.

What actually happened? Please include the actual, raw output from ESLint.

ESLint: 5.1.0.
No files matching the pattern "node_modules/complex.js" were found.
Please check for typing mistakes in the pattern.

This happened for complex.js, decimal.js and fraction.js. The correct path for the three of them is, for instance, node_modules/complex.js/complex.js. If I move the file to node_modules/complex.js eslint works fine but actually running the script breaks as it looks for node_modules/complex.js/complex.js.

@eslint-deprecated eslint-deprecated bot added the triage An ESLint team member will look at this issue soon label Jul 12, 2018
@platinumazure
Copy link
Member

Hi @gnobre, thanks for the issue.

Do you mean to lint in node_modules? That's not something we usually recommend.

I think due to the name of the complex.js package, your glob pattern is matching up to the folder name rather than the filename. That said, the glob pattern is probably being handled by your shell, not ESLint. Perhaps you could try quoting the glob pattern? Then ESLint would be handling the glob, and maybe our glob logic would pick up the necessary files.

@gnobre
Copy link
Author

gnobre commented Jul 17, 2018

That was exactly it! I just had to add quotes to the pattern: eslint '**/*.js'

Working like a charm, thank you.

@gnobre gnobre closed this as completed Jul 17, 2018
platinumazure pushed a commit that referenced this issue Jul 28, 2018
* Chore: mv lib/ast-utils => lib/util/ast-utils (refs #10559)

* Chore: rename *-util => *-utils (refs #10559)
@vvscode
Copy link

vvscode commented Nov 22, 2018

it doesn't work in 5.9.0

@not-an-aardvark
Copy link
Member

@vvscode Please create a new issue or join our Gitter channel if you're having trouble. Thanks!

@eslint-deprecated eslint-deprecated bot locked and limited conversation to collaborators Jan 14, 2019
@eslint-deprecated eslint-deprecated bot added the archived due to age This issue has been archived; please open a new issue for any further discussion label Jan 14, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
archived due to age This issue has been archived; please open a new issue for any further discussion triage An ESLint team member will look at this issue soon
Projects
None yet
Development

No branches or pull requests

4 participants