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

lintstagedrc.js failes on Windows #70

Open
JeffBaumgardt opened this issue Oct 2, 2018 · 1 comment
Open

lintstagedrc.js failes on Windows #70

JeffBaumgardt opened this issue Oct 2, 2018 · 1 comment

Comments

@JeffBaumgardt
Copy link

  • node version: 10.10.0
  • npm (or yarn) version: 6.0.0

Relevant code or config

npm run precommit

Problem description:

I'm working on a fork of kcd-scripts for my own company's purposes and while testing the lintstagedrc.js file failes on Windows. Probably has to do with #8 or is very similar. I also noticed this when working on React-Testing-Library when I went to commit, again lintstagedrc.js fails.

Unfortunately I'm not versed enough in the fs and path operators to figure out how to change \ for /. Unless we write a dirty method to check for win32 and do a global replace on the path string, tranding slashes. But I don't know what other problems might arise from that.

@JeffBaumgardt
Copy link
Author

Probably a separate issue and but I get the same popup Windows Script Host complaining about dist\run-script.js on line 3. Reading the outputted source shows that to be the require('path') which makes no sense. Unfortunately windows isn't good here at troubleshooting errors.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants