BrowserSync : Command not found after installing browser-sync

天大地大妈咪最大 提交于 2019-11-28 00:44:23

问题


There was another issue open with the same title which has been closed but my error could not be resolved using the solutions given in that issue.

  • Mac OSX El Capitan
  • Node [v5.6.0]
  • Npm [v3.6.0]

I installed Browser-Sync successfully using : bash $ sudo npm install -g browser-sync

but when I check the browser-sync version by typing : bash $ browser-sync --version

I get this error : bash -bash: browser-sync: command not found


回答1:


Check where npm installs it's binaries by running npm bin -g, and then add that to your PATH.

export PATH=$PATH:/usr/local/bin


来源:https://stackoverflow.com/questions/35500178/browsersync-command-not-found-after-installing-browser-sync

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