Skip to content

Commit

Permalink
feat(symlinks): change how zellij is started, to open welcome page
Browse files Browse the repository at this point in the history
  • Loading branch information
trystan2k committed Jun 27, 2024
1 parent 3129e26 commit be5ccfa
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions symlinks/.zshrc
Original file line number Diff line number Diff line change
Expand Up @@ -161,15 +161,7 @@ set-npmrc-config-hook() {
add-zsh-hook chpwd set-npmrc-config-hook

if [ -z "$ZELLIJ" ] && [ "$TERM" = "xterm-kitty" ]; then
ZJ_SESSIONS=$(zellij list-sessions)
NO_SESSIONS=$(echo "${ZJ_SESSIONS}" | wc -l)

if [ "${NO_SESSIONS}" -ge 2 ]; then
SESSION_TO_ATTACH=$(echo "${ZJ_SESSIONS}" | fzf --ansi | sed 's/ .*//')
zellij attach $SESSION_TO_ATTACH
else
zellij attach -c
fi
zellij -l welcome
fi

if [ -f "$HOME"/.exports.path ]; then
Expand Down

0 comments on commit be5ccfa

Please sign in to comment.