ZSH initialization file load sequence: | {/etc/zshenv} | | | (is NO_RCS set?[1]) | | [yes] | [no] ---------------------------------- | | | | | {$ZDOTDIR/.zshenv} | | | | (is this a login shell?[2]) | | | [yes] | [no] | ------------------------------- | | | | {/etc/zprofile} | | | | (is this shell | {$ZDOTDIR/.zprofile} | interactive?[3]) | | | | | [yes] | [no] | | ------------------- | | | | | {/etc/zshrc} {/etc/zshrc} | | | | | | {$ZDOTDIR/.zshrc} {$ZDOTDIR/.zshrc} | | | | | | | | | | {/etc/zlogin} | | | | | | | {$ZDOTDIR/.zlogin} | | | | | | | | | | **************************************************************** * SHELL * **************************************************************** | | | | | | (is NO_RCS | | | | set?[1]) | | | | | | | [yes] | [no] | | | ------------------- | | | | | | | | | {$ZDOTDIR/.zlogout} | | | | | | | | | {/etc/zlogout} | | | | | | | x x x x x Tests are matched as follows, in increasing order of precedence; `unsetopt OPTION' is equivalent to `setopt NO_OPTION' and `unsetopt NO_OPTION' is equivalent to `setopt OPTION' in terms of precedence. For example, zsh -f with `unsetopt NO_RCS' in /etc/zshenv will source /etc/zshenv, $ZDOTDIR/.zshenv, /etc/zshrc, and $ZDOTDIR/.zshrc. [1] DEFAULT => [no] `setopt NO_RCS' called before test => [yes] `-f' flag present on shell invocation => [yes] `setopt RCS' called before test => [no] [2] DEFAULT => [no] first character of argument zero (name by which zsh is invoked) is `-' => [yes] `-l' flag present on shell invocation => [yes] [3] DEFAULT => [no] `-i' flag present on shell invocation => [yes] standard input is a tty and commands are being read from standard input => [yes]