mac下配置环境变量要修改~/.bash_profile然后执行source ~/.bash_profile
但是每次打开终端,要重新执行source ~/.bash_profile
解决方法:
在 ~/.zshrc文件下,最后一行添加source .bash_profile
ps:/.bash_profile和/.zshrc不存在的话要自行创建。
mac下配置环境变量要修改~/.bash_profile然后执行source ~/.bash_profile
但是每次打开终端,要重新执行source ~/.bash_profile
解决方法:
在 ~/.zshrc文件下,最后一行添加source .bash_profile
ps:/.bash_profile和/.zshrc不存在的话要自行创建。