npm hangs on any command

后端 未结 6 1055
庸人自扰
庸人自扰 2021-01-01 20:01

I installed last version of Node.js (12.2 x64 windows) After I run cmd as administrator and try to call any npm command (except npm -v

6条回答
  •  伪装坚强ぢ
    2021-01-01 20:35

    For clarity, when you call:

    npm config set prefix 'c:\npm'
    

    you are required to have the ' wrapping the path, but you need to remove them from the .npmrc file so that npm commands will work. So your resulting line in .npmrc file should look like:

    prefix="c:\\npm"
    

提交回复
热议问题