-
Notifications
You must be signed in to change notification settings - Fork 485
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
Glob pattern does not work on windows #607
Comments
Thanks for the report. This was previously discussed in #335 I'm not sure what to do in this case. Globs are a console feature, not a documentation.js feature. When you say Are you using Windows PowerShell or another type of shell in Windows? PowerShell should support globs as wikipedia says. There are multiple possible actionables here:
|
Ah, sorry for the duplicate! How about using something like https://github.com/isaacs/node-glob in documentation.js? |
Looking into the glob implementation here, but can you confirm which shell you're using in Windows? PowerShell should have support, as should cygwin. This is troubling to me because of this case:
The problem here is:
Illustrative example: test.js: console.log(process.argv.slice(2)); output:
So, implementing Very interested in if anyone has solutions here, of can write documentation for people to use Windows glob patterns to dodge this problem. |
This brings logic from eslint over to documentation: instead of readdirSync, we're using the glob module. This also, I hope, will let us support globs on Windows without changing OSX/Linux behavior. Fixes #607
eslint actually does this 🙌 , praise eslint! The trick is:
The magic is in https://github.com/eslint/eslint/blob/master/lib/util/glob-util.js Got an initial port of the eslint logic at #629 |
Gday @tmcw Just confirming that the glob issue does occur on windows even when using powershell. I'll keep an eye on the issue and your pull request as am currently looking at tidying up the turf docs but I currently can't do anything with them :( |
This brings logic from eslint over to documentation: instead of readdirSync, we're using the glob module. This also, I hope, will let us support globs on Windows without changing OSX/Linux behavior. Fixes #607
This brings logic from eslint over to documentation: instead of readdirSync, we're using the glob module. This also, I hope, will let us support globs on Windows without changing OSX/Linux behavior. Fixes #607
This brings logic from eslint over to documentation: instead of readdirSync, we're using the glob module. This also, I hope, will let us support globs on Windows without changing OSX/Linux behavior. Fixes #607
This brings logic from eslint over to documentation: instead of readdirSync, we're using the glob module. This also, I hope, will let us support globs on Windows without changing OSX/Linux behavior. Fixes #607
results in
on windows, but works as expected on linux/osx
The text was updated successfully, but these errors were encountered: