一、打开MAC电脑的shell 图1 shell 二、命令行下敲ls -la 找到.bashrc 图2 .bashrc 三、使用vim打开.bashrc 图3 .bashrc 四、添加环境变量到全局 export PATH=$PATH: 路径 PATH=$PATH 是要继承原来添加的环境变量