Problems with “zsh: command not found: sails”

心不动则不痛 提交于 2021-02-05 07:52:25

问题


I installed sails.js with via sudo npm install -g sails but i'm still getting zsh: command not found: sails

I'm using Ubuntu 14.04 LTS.


回答1:


First find out path for node which node will return something like /path/bin/node

enter that location to bin cd /path

uninstall present node by running rm -r bin/node bin/node-waf include/node lib/node lib/pkgconfig/nodejs.pc share/man/man1/node.1

then you'll want to install nvm by running curl https://raw.githubusercontent.com/creationix/nvm/v0.19.0/install.sh | bash then . ~/.nvm/nvm.sh and nvm install stable

install node npm -g i node

finally install sails globally npm -g i sails

you should be good to build you first sails project



来源:https://stackoverflow.com/questions/34815540/problems-with-zsh-command-not-found-sails

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!