Dotfiles still being ignored with version 6.8.0
See original GitHub issueTell us about your environment
- Node version: v13.7.0
- npm version: v6.13.6
- Local ESLint version: v6.8.0 (Currently used)
- Global ESLint version: Not found
What parser (default, Babel-ESLint, etc.) are you using?
default
Please show your full configuration:
Configuration
const defaults = {
"env": {
"browser": true,
"es6": true
},
"extends": "eslint:recommended",
"globals": {
"Atomics": "readonly",
"SharedArrayBuffer": "readonly"
},
"parserOptions": {
"ecmaVersion": 2018,
"sourceType": "module"
},
"rules": {
},
}
module.exports = {
...defaults,
overrides: [{
files: ['.my-dotfile.js'],
...defaults
}]
};
What did you do? Please include the actual source code causing the issue, as well as the command that you used to run ESLint.
Dot files are being ignored, even when explicitly set in the overrides
section. See config.
yarn run eslint .my-dotfile.js # ignores file despite explicitly naming it
yarn run eslint . # ingores file too despite being explicitly set in overrides section in config
What did you expect to happen?
The .my-dotfile.js
file should have been linted
What actually happened? Please include the actual, raw output from ESLint.
It did not lint the file
/home/ayzing/workspace/repro-eslint-dotfiles-not-working/.my-dotfile.js
0:0 warning File ignored by default. Use a negated ignore pattern (like "--ignore-pattern '!<relative/path/to/filename>'") to override
✖ 1 problem (0 errors, 1 warning)
Are you willing to submit a pull request to fix this bug?
Not at this time. Here’s a sample repo to help with the debugging.
Issue Analytics
- State:
- Created 4 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
Migrating to v7.0.0 - ESLint - Pluggable JavaScript Linter
Default ignore patterns have changed Up until now, ESLint has ignored the following files by default: Dotfiles ( . * ) node_modules in...
Read more >Puppet release notes
Puppet agent --disable is ignored with cron puppet agent (splay). Puppet agent now checks the disabled lock file after sleeping due to splay....
Read more >https://maps.london.gov.uk/gitea/gla-intelligence/...
yarn lockfile v1 "@babel/code-frame@7.0.0-beta.44": version "7.0.0-beta.44" ... babel-plugin-syntax-export-extensions@^6.8.0: version "6.13.0" resolved ...
Read more >/yarn.lock | lodash@4.17.19 | Deno
A modern JavaScript utility library delivering modularity, performance, & extras.
Read more >https://git.asonix.dog/asonix/mastodon/commit/ffab...
+# yarn lockfile v1 +"@kadira/react-split-pane@^1.4.0": + version "1.4.7" + ... + lodash "^4.2.0" + +babel-helper-call-delegate@^6.8.0: + version "6.8.0" + ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
overrides
still respects ignore patterns, so you’ll want to follow the suggestion given in the error message. Alternatively, you can use an.eslintignore
file or by specifyingignorePatterns
in your configuration.Unrelated to this, but overrides are merged into the top-level config (the intention is to allow users to override the base config for specific files), so you don’t need to merge
defaults
into theoverrides
entry.Great, and good to know @kaicataldo ! And now also answers a very important question… who lints the linters? (spoilers: it’s also the linters 😄 )