Because in the original article Bo Master said the following is a netizen said, so I just add a turn, can not find the original author
/ETC/PROFILE,/ETC/BASHRC is the system Global environment variable setting
~/.PROFILE,~/.BASHRC private environment variable settings in the user home directory
When a shell process is acquired while logged into the system, it has three steps to read the Environment profile
1 first read the Global environment variable profile/etc/profile, and then read the additional set of documents according to its contents, such as
/ETC/PROFILE.D and/ETC/INPUTRC
2 then according to different user account, go to their home directory read ~/.bash_profile, if this can not read the ~/.bash_login, this also can not read to read
~/.profile, these three document settings are basically the same, reading has a priority relationship
3 then read the ~/.BASHRC according to the user account
As for the difference between ~/.profile and ~/.BASHRC
are individually customizable
~/.profile can set the user's proprietary path, environment variables, etc., it only to log in when the execution of the time
~/.BASHRC is also a user-specific settings document, you can set the path, command alias, each time the shell script execution will use it once
The difference between/etc/profile,/etc/bashrc,~/.profile,~/.bashrcd in "Turn" Linux