Mac系统的环境变量,加载顺序

Mac系统的环境变量,加载顺序为:
a. /etc/profile
b. /etc/paths
c. ~/.bash_profile
d. ~/.bash_login
e. ~/.profile
f. ~/.bashrc
其中a和b是系统级别的,系统启动就会加载,其余是用户接别的。c,d,e按照从前往后的顺序读取,如果c文件存在,则后面的几个文件就会被忽略不读了,以此类推。~/.bashrc没有上述规则,它是bash shell打开的时候载入的。这里建议在c ~/.bash_profile 中添加环境变量

Author

陈昭

Posted on

2021-12-20

Updated on

2021-12-27

Licensed under

You need to set install_url to use ShareThis. Please set it in _config.yml.
You forgot to set the business or currency_code for Paypal. Please set it in _config.yml.

Kommentare

You forgot to set the shortname for Disqus. Please set it in _config.yml.