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 rules with slash not working on Windows #22

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

RedMser
Copy link
Contributor

@RedMser RedMser commented Jan 16, 2022

I assume that optionator parses strings as file names (as there's a similar bug reported here), so on Windows it turns slashes in rule names into backslashes.

I haven't encountered rules that contain spaces, so this may be enough to fix related issues for now.

I assume that optionator parses strings as file names, so on Windows it turns slashes into backslashes.
@IanVS
Copy link
Owner

IanVS commented Jan 16, 2022

Hi, thanks for the PR! Can you give an example of a rule name that currently fails in windows? This package is used in https://github.com/IanVS/eslint-nibble, and I haven't heard any reports of windows failures, so I'd like to make sure I clearly understand what is going on.

@RedMser
Copy link
Contributor Author

RedMser commented Jan 16, 2022

Hi, I did some more research and it actually seems to be related to npx, as running your CLI directly via node works as expected. I found a similar issue here, which got resolved by updating node and npm.

So I assume this fix isn't strictly needed, since your code is working as intended, but maybe a disclaimer on the readme or the like...

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

Successfully merging this pull request may close these issues.

2 participants