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

global npx installation is shadowed by nodejs on Windows #21001

Closed
saschanaz opened this issue May 28, 2018 · 3 comments
Closed

global npx installation is shadowed by nodejs on Windows #21001

saschanaz opened this issue May 28, 2018 · 3 comments
Labels
npm Issues and PRs related to the npm client dependency or the npm registry. wrong repo Issues that should be opened in another repository.

Comments

@saschanaz
Copy link

saschanaz commented May 28, 2018

  • Version: 10.2.1
  • Platform: Windows 10 64-bit
  • Subsystem:
> npx --version
npx: installed 1 in 11.516s
The "path" argument must be of type string. Received type undefined
9.7.1
> npm i -g npx
+ npx@10.2.0
updated 1 package in 70.955s
> npx --version
npx: installed 1 in 9.741s
The "path" argument must be of type string. Received type undefined
9.7.1

See also zkat/npx#144 (comment).

@bnoordhuis bnoordhuis added npm Issues and PRs related to the npm client dependency or the npm registry. wrong repo Issues that should be opened in another repository. labels May 28, 2018
@bnoordhuis
Copy link
Member

Wrong repo. npx is a dependency of npm and is installed per directions of npm, see #14235. If you want to see it changed, open an issue over at npm/npm.

@saschanaz
Copy link
Author

saschanaz commented May 28, 2018

@bnoordhuis, I opened this because the Node.js installer for Windows adds special alias for npx and that conflicts with npm because of path order.

gcm npx points to nodejs where it should point to npm:

> gcm npx

CommandType     Name                                               Version    Source
-----------     ----                                               -------    ------
Application     npx.cmd                                            0.0.0.0    C:\Program Files\nodejs\npx.cmd

@bnoordhuis
Copy link
Member

The changes to the installer were made by an npm employee - by the author of npx, in fact. If something needs to change, discuss it with npm and they'll update the installer next time they upgrade npm in node.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
npm Issues and PRs related to the npm client dependency or the npm registry. wrong repo Issues that should be opened in another repository.
Projects
None yet
Development

No branches or pull requests

2 participants