[zsh] Only print tmux sessions for LOGIN shells

While playing around with neovide, I learned that processes can reasonably
expect non-login shells to print nothing except commands to execute. This change
modifies zshrc to only print tmux sessions (something I only care about when I
start a shell myself) in LOGIN shells.
This commit is contained in:
Eryn Wells 2024-08-02 18:20:47 -07:00
parent 30f5bb7d29
commit 05606d745f
2 changed files with 6 additions and 1 deletions

6
zshrc
View file

@ -14,6 +14,12 @@ zsh_init_rc_functions=( \
init_rc_$SYS \
)
if [[ -o LOGIN ]]; then
zsh_init_rc_functions+=(
list_tmux_sessions \
)
fi
do_init_functions zsh_init_rc_functions
autoload -Uz g