更新时间:2023-09-11 22:32:34
我希望这对某人有所帮助,但同样的情况发生在我身上,我只需要在尝试使用它之前重新启动终端.我的意思是,在使用 npm i -g @vue/cli
安装 vue-cli 后,重新启动终端或使用以下内容更新源代码:source ~/.bash_profile
(或只是重新启动终端,更容易)因此您的配置文件中的路径会更新:).那为我修好了.
I hope this helps somebody but the same happened to me, I just had to restart the terminal before attempting to use it. I mean, after install vue-cli with npm i -g @vue/cli
restart the terminal or update the source with something like: source ~/.bash_profile
(or just restart the terminal, is easier) so the path in your profile gets updated :). That fixed it for me.