Shell customization files

It can sometimes be a little confusing where to put customizations for your shell environment. Below are a few tips:


  • .bash_profile (when you log in)
    • Use to run commands that should run only once, such as customizing the $PATH
  • .bashrc (when you open a shell)
  • .profile
    • The ~/.profile file is read by all shells, while ~/.bash_profile only by Bash.

@khem maybe you want to add tips on zsh :slight_smile:

Zsh has bunch of config files, There are explained well in this article