在ubuntu上装了node.js后,npm install hexo-cli -g 提示没装npm,怎么办
大家讲道理2017-04-17 13:10:06
Is nodejs pretending to be disabled?
You can view the global installation path via
npm config get prefix
,
via
npm config set prefix=path
阿神2017-04-17 13:10:06
If you use apt-get install nodejs npm, you need to install it separately
Official installation instructions
NOTE: If you are using Ubuntu Precise or Debian Wheezy, you might want to read about running Node.js >= 4.x on older distros.
curl -sL https://deb.nodesource.com/setup_4.x | sudo -E bash - sudo apt-get install -y nodejs
Alternatively, for Node.js v6:
curl -sL https://deb.nodesource.com/setup_6.x | sudo -E bash - sudo apt-get install -y nodejs