Pana / nrm

NPM registry manager, fast switch between different registries: npm, cnpm, nj, taobao
MIT License
2.79k stars 244 forks source link

command not found: nrm #88

Closed HomyeeKing closed 3 years ago

HomyeeKing commented 3 years ago

after global installed , zsh can't find command

wewang-sh commented 3 years ago

same problem, did you resolve this?

HomyeeKing commented 3 years ago

@wewang-sh you can follow the below:

# check the npm global bin location
npm -g bin  
#or 
which npm

# then check  wether the PATH  has the npm global path or not
echo $PATH

if you not find the npm global path in the PATH or the path is not right, you can prepend it or just modify the npm global path with the npm cofig set prefix <the target path> command

wewang-sh commented 3 years ago

my problem caused by resolving npm i -g need sudo on macos with wrong way , and i fixed it by stepping https://docs.npmjs.com/resolving-eacces-permissions-errors-when-installing-packages-globally @HomyeeKing thanks bro