I understand the difference between .bashrc
and .bash_profile
(or .bash_login
and ~/.profile
for that matter), but is there any particular reason to choose .bashrc
over .bash_profile
for bash shell configuration?
From my understanding, configuration such as terminal colors, environmental variables, etc. in .bashrc
will be re-loaded every time a new bash window is open. .bash_profile
will only get loaded once at login, and I think that should be enough. Why put anything in .bashrc
then?
The only reason I can think of is to avoid having to log out of the system for a configuration to be loaded.
I couldn't find an answer besides purely conventional reasons.