步骤
安装 node.js [1]
# Using Ubuntu
curl -sL https://deb.nodesource.com/setup_7.x | sudo -E bash -
sudo apt-get install -y nodejs
setup npm [2]
curl -L https://www.npmjs.com/install.sh | sh
权限错误 [3]
解决方案
npm config set user 0
npm config set unsafe-perm true
参考文献
1. node.js: https://github.com/nodesource/distributions
2. nmp: https://github.com/npm/npm
3. 权限错误: https://www.cnblogs.com/lidonghao/p/3543747.html
4. hexo 环境搭建: http://www.voidking.com/2015/05/30/deve-hexo-build-environment/
(全文完)