Skip to content

Specify --ignore-path for ESLint #1443

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

Merged
merged 1 commit into from
Mar 21, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 2 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,8 @@
],
"scripts": {
"test": "c8 --reporter=html --reporter=text mocha \"test/*/_index.js\" \"**/*.test.js\" --ignore=\"node_modules/**\"",
"lint": "eslint . && prettier --list-different \"**/*.js\" --ignore-path .gitignore",
"fix": "eslint . --fix && prettier --write \"**/*.js\" --ignore-path .gitignore",
"lint": "eslint --ignore-path .gitignore . && prettier --list-different \"**/*.js\" --ignore-path .gitignore",
"fix": "eslint --ignore-path .gitignore --fix . && prettier --write \"**/*.js\" --ignore-path .gitignore",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I used "ignorePatterns" in eslint config. So not all.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd say better remove ignorePatterns then and just use .gitignore. It's the right file and includes everything that needs to be ignored.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, you can remove

"typecheck": "tsc",
"test-browser": "rollup -c && node ./test/browser.js",
"test-regression": "NO_DIFF=1 node ./test/regression.js",
Expand All @@ -61,10 +61,6 @@
"singleQuote": true
},
"eslintConfig": {
"ignorePatterns": [
"dist",
"fixtures"
],
"parserOptions": {
"ecmaVersion": "2021"
},
Expand Down
2 changes: 1 addition & 1 deletion test/config/fixtures/invalid/svgo.config.js
Original file line number Diff line number Diff line change
@@ -1 +1 @@
module.exports = { plugins };
module.exports = { plugins }; // eslint-disable-line no-undef