zkat / npx

execute npm package binaries (moved)
https://github.com/npm/npx
Other
2.63k stars 105 forks source link

fix(windows): escape prefix path on windows #138

Closed brianpeiris closed 6 years ago

brianpeiris commented 6 years ago

Closes #100

brianpeiris commented 6 years ago

escapeArgs asPath wouldn't have worked here. npm wants the whole path quoted on windows.

brianpeiris commented 6 years ago

Hmm. Not sure why some tests timed out on travis. Will look into it later.

Also interesting to note that the test suite was failing on my windows machine, since my user directory has a space in it. Appveyor's user does not have any spaces. The test suite passes on my machine with this fix.

zkat commented 6 years ago

@brianpeiris This project was relicensed to ISC (from CC0-1.0) since you put up this PR. Are you ok with me merging this under that license instead?

brianpeiris commented 6 years ago

Yup, fine with me.

Pamelapelkola commented 6 years ago

Is there any update on this issue? I cannot use npm on my machine because of it.

zkat commented 6 years ago

cc @noahleigh does this seem alright to you?

noelleleigh commented 6 years ago

@zkat It works for me. My only question is whether it would be better to use child.escapeArg rather than manual quoting, since that function seems to be purpose-built for this kind of scenario (with platform-specific conditions built-in)?

zkat commented 6 years ago

Closing this in favor of #181 (which includes @brianpeiris' commit)