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

Fix eslint trying to look at node_modules/ #275

Merged

Conversation

MadLittleMods
Copy link
Contributor

@MadLittleMods MadLittleMods commented Jun 27, 2023

Fix eslint trying to look at node_modules/. I'm not sure what exactly is causing the behavior change now besides that I am running on Linux.

The quote fix around the path is from https://stackoverflow.com/questions/51021751/express-js-lint-gives-mistake

node_modules/ is already part of our .eslintignore

https://github.com/matrix-org/matrix-public-archive/blob/1d3e930fbd57788ed60494a64835127ff97dbd53/.eslintignore#L1

Previously:

$ npm run lint

> matrix-public-archive@0.1.0 lint
> eslint **/*.js

Oops! Something went wrong! :(

ESLint: 8.37.0

You are linting "node_modules/ipaddr.js", but all of the files matching the glob pattern "node_modules/ipaddr.js" are ignored.

If you don't want to lint these files, remove the pattern "node_modules/ipaddr.js" from the list of arguments passed to ESLint.

If you do want to lint these files, try the following solutions:

* Check your .eslintignore file, or the eslintIgnore property in package.json, to ensure that the files are not configured to be ignored.
* Explicitly list the files from this glob that you'd like to lint on the command-line, rather than providing a glob as an argument.

Previously:

```sh
$ npm run lint

> matrix-public-archive@0.1.0 lint
> eslint **/*.js

Oops! Something went wrong! :(

ESLint: 8.37.0

You are linting "node_modules/ipaddr.js", but all of the files matching the glob pattern "node_modules/ipaddr.js" are ignored.

If you don't want to lint these files, remove the pattern "node_modules/ipaddr.js" from the list of arguments passed to ESLint.

If you do want to lint these files, try the following solutions:

* Check your .eslintignore file, or the eslintIgnore property in package.json, to ensure that the files are not configured to be ignored.
* Explicitly list the files from this glob that you'd like to lint on the command-line, rather than providing a glob as an argument.
```
@MadLittleMods MadLittleMods added the T-Task Refactoring, removal, replacement, enabling or disabling functionality, other engineering tasks. label Jun 27, 2023
@MadLittleMods MadLittleMods marked this pull request as ready for review June 27, 2023 22:14
@MadLittleMods MadLittleMods merged commit 2243db5 into main Jun 27, 2023
6 checks passed
MadLittleMods added a commit that referenced this pull request Jun 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
T-Task Refactoring, removal, replacement, enabling or disabling functionality, other engineering tasks.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant