mac os 下安装出错

按照中文wiki第二节 安装pomelo
安装pomelo

$ npm install pomelo -g

出现错误
npm ERR! Darwin 16.4.0
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "install" "pomelo" "-g"
npm ERR! node v6.9.5
npm ERR! npm v3.10.10
npm ERR! path /usr/local/lib/node_modules
npm ERR! code EACCES
npm ERR! errno -13
npm ERR! syscall access

npm ERR! Error: EACCES: permission denied, access '/usr/local/lib/node_modules'
npm ERR! at Error (native)
npm ERR! { Error: EACCES: permission denied, access '/usr/local/lib/node_modules'
npm ERR! at Error (native)
npm ERR! errno: -13,
npm ERR! code: 'EACCES',
npm ERR! syscall: 'access',
npm ERR! path: '/usr/local/lib/node_modules' }
npm ERR!
npm ERR! Please try running this command again as root/Administrator.

npm ERR! Please include the following file with any support request:

提示权限不过,改用 sodu npm install pomelo -g,安装成功。
如果必须使用sodu,请更新下文档,给后续菜鸟一个方便。

标签: 建议与改进
huangtao117 在 3-18 12:00发布 分享到 weibo
回到顶部