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 does not accept spaces in the path? #42588

Closed
carolinan opened this issue Jul 21, 2022 · 3 comments · Fixed by #61748
Closed

ESLint does not accept spaces in the path? #42588

carolinan opened this issue Jul 21, 2022 · 3 comments · Fixed by #61748
Labels
[Package] ESLint plugin /packages/eslint-plugin [Status] In Progress Tracking issues with work in progress [Type] Enhancement A suggestion for improvement.

Comments

@carolinan
Copy link
Contributor

Description

I am using Local and the path to where I placed Gutenberg is:
/Users/carolina/Local Sites/60/app/public/wp-content/plugins/gutenberg-git

Using the GitHub Desktop app to submit an update to a branch with a pull request, I received this error:


✖ wp-scripts format found some errors. Please fix them and try committing again.

[error] No files matching the pattern were found: "/Users/carolina/Local".
[error] No files matching the pattern were found: "Sites/60/app/public/wp-content/plugins/gutenberg-git/packages/block-library/src/post-navigation-link/edit.js".



✖ wp-scripts lint-js found some errors. Please fix them and try committing again.
  
  
Oops! Something went wrong! :(

ESLint: 8.3.0

No files matching the pattern "/Users/carolina/Local" were found.
Please check for typing mistakes in the pattern.
husky - pre-commit hook exited with code 1 (error)

It seems to be splitting Local and Sites?

Step-by-step reproduction instructions

  1. Set up Local for WordPress development with their default folder names
  2. Clone Gutenberg into the plugin directory
  3. Checkout the branch you are working on.
  4. Make your changes and try to commit them to the branch.

Screenshots, screen recording, code snippet

Screen Shot 2022-07-21 at 09 53 53

Environment info

Local, version 6.4.1+5978
Mac OS 12.4

Please confirm that you have searched existing issues in the repo.

Yes

Please confirm that you have tested with all plugins deactivated except Gutenberg.

Yes

@t-hamano t-hamano added the [Package] ESLint plugin /packages/eslint-plugin label Jul 24, 2022
@t-hamano
Copy link
Contributor

I also tested it and reproduced it when the directory contains spaces.
This same problem has been reported on ESLint and still seems to be unresolved.

eslint/eslint#14025

It might be good to leave this issue open in the hope that it will be fixed by the library.

@ndiego
Copy link
Member

ndiego commented Aug 6, 2022

I have also been running into this. Very frustrating. @carolinan have you found a reliable workaround? I am just renaming the folder, committing, and then reverting the name. Not ideal 😅

@carolinan
Copy link
Contributor Author

carolinan commented Aug 7, 2022

I renamed the folder permanently.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Package] ESLint plugin /packages/eslint-plugin [Status] In Progress Tracking issues with work in progress [Type] Enhancement A suggestion for improvement.
Projects
None yet
4 participants