相关文件
/etc/bashrc
/etc/profile
~/.bashrc
~/.bash_profile
加载时机:
/etc/profile 和 ~/.bash_profile 只在用户登陆时加载
/etc/bashrc 和 ~/.bashrc 则在每次启动bash时都会加载
用户登陆时加载顺序:
1. /etc/profile
2. ~/.bash_profile
3. ~/.bashrc
4. /etc/bashrc
用户登陆后执行bash加载顺序:
1. ~/.bashrc
2. /etc/bashrc