美文网首页
mac安装vue后,启动项目,vue command not f

mac安装vue后,启动项目,vue command not f

作者: 大脸猫_2e21 | 来源:发表于2019-10-28 12:48 被阅读0次

最近配置新的mac,全局安装vue和vue-cli之后准备,开始建一个demo试试,结果在执行命令

vue init webpack xxx
// vue command not found

在.bash_profile中添加

//将路径改为自己的路径 在bash_profile中进行添加
export PATH=${PATH}:/usr/local/node/lib/node_modules/lib/node_modules/vue-cli/bin

添加完路径之后,执行

source .bash_profile

在~/.zshrc文件最后,增加一行:

source ~/.bash_profile

相关文章

网友评论

      本文标题:mac安装vue后,启动项目,vue command not f

      本文链接:https://www.haomeiwen.com/subject/eoovvctx.html