美文网首页
mac 终端报错 zsh: command not found:

mac 终端报错 zsh: command not found:

作者: 阳光下的灰尘 | 来源:发表于2022-03-04 10:14 被阅读0次

修改 ~/.zshrc 文件
.zshrc 文件中添加路径
在终端中使用 open .zshrc 命令打开文件:
添加
PATH=/bin:/usr/bin:/usr/local/bin:${PATH}
export PATH
再重新打开终端,应该已经解决 zsh: command not found: xxx 问题

如果在 ~/.bash_profile 里配置了其他如 flutter 环境,需要在 ~/.zshrc 添加:
source ~/.bash_profile 执行

相关文章

网友评论

      本文标题:mac 终端报错 zsh: command not found:

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