A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/rbenv/rbenv/wiki/Unix-shell-initialization below:

Unix shell initialization · rbenv/rbenv Wiki · GitHub

Shell initialization files are ways to persist common shell configuration, such as:

Which initialization files get sourced by the shell is dependent on the combination of modes in which a particular shell process runs. There are two main, non-exclusive modes:

These modes can be manually activated with the following flags to bash/zsh:

Here are some common operations and shell modes they result in:

In order of activation:

  1. login mode:
    1. /etc/profile
    2. ~/.bash_profile, ~/.bash_login, ~/.profile (only first one that exists)
  2. interactive non-login:
    1. /etc/bash.bashrc (some Linux; not on Mac OS X)
    2. ~/.bashrc
  3. non-interactive:
    1. source file in $BASH_ENV
  1. /etc/zshenv
  2. ~/.zshenv
  3. login mode:
    1. /etc/zprofile
    2. ~/.zprofile
  4. interactive:
    1. /etc/zshrc
    2. ~/.zshrc
  5. login mode:
    1. /etc/zlogin
    2. ~/.zlogin
  1. login mode:
    1. /etc/profile
    2. ~/.profile
  2. interactive:
    1. source file in $ENV
  1. <install-prefix>/config.fish
  2. /etc/fish/config.fish
  3. ~/.config/fish/config.fish
Practical guide to which files get sourced when Misc. things that affect $PATH

This guide was tested with:

On these operating systems/apps:

See also:


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4