在ubuntu上安装hubot时出错

时间:2015-06-23 09:44:15

标签: node.js ubuntu hubot

当我运行yo hubot时,出现以下错误

npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "install" "hubot"
"hubot-scripts" "hubot-diagnostics" "hubot-help" "hubot-heroku-keepalive" "hubot-google-images"
"hubot-google-translate" "hubot-pugme" "hubot-maps" "hubot-redis-brain"
 "hubot-rules" "hubot-shipit" "--save"

为什么会这样?我试过运行sudo npm install hubot-rules但它似乎不起作用。请帮忙!

1 个答案:

答案 0 :(得分:1)

原来你需要拥有~/.npm目录。您可以运行此命令来执行此操作:

$ sudo chown -R $(whoami) "$HOME/.npm"