1111mp / nvm-desktop

Node Version Manager Desktop - A desktop application to manage multiple active node.js versions.
https://github.com/1111mp/nvm-desktop
MIT License
675 stars 34 forks source link

The global npm package command cannot be used #7

Closed lainbo closed 10 months ago

lainbo commented 11 months ago

I checked with npm list -g --depth 0 to see that the node version is correct, and also installed the global packages I want, but none of the global commands for those packages work. Did I do something wrong? image image


I'm using Windows 11 22H2 22621.2361. node is node 18.18.0 downloaded using nvm-desktop

1111mp commented 11 months ago

Which version of nvm-desktop application are you using, and did you install the global package through npm install yarn -g command?

If everything goes well, the shim corresponding to the global package should be added to your file directory: %HOMEPATH%/.nvmd/bin/yarn.exe & %HOMEPATH%/.nvmd/bin/yarn.cmd.

image

(Forgive me for the Macos use case, but the situation on Windows platform is similar)

Maybe you can check the system environment variables: %HOMEPATH%/.nvmd/bin or run nvmd -hcheck if it takes effect.