Skip to content

Commit b1cc6b4

Browse files
authored
Merge pull request #1 from ithaquaKr/fix-default-shell-zsh
fix: fix default shell zsh
2 parents cff343c + 009a2a5 commit b1cc6b4

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

scripts/restore.sh

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -109,8 +109,9 @@ tmux_socket() {
109109
cache_tmux_default_command() {
110110
local default_shell="$(get_tmux_option "default-shell" "")"
111111
local opt=""
112-
if [ "$(basename "$default_shell")" == "bash" ]; then
113-
opt="-l "
112+
local available_shells=(zsh bash)
113+
if [[ " ${available_shells[*]} " =~ " $(basename "$default_shell") " ]]; then
114+
opt="-l "
114115
fi
115116
export TMUX_DEFAULT_COMMAND="$(get_tmux_option "default-command" "$opt$default_shell")"
116117
}

0 commit comments

Comments
 (0)