diff --git a/.zshrc b/.zshrc index a65c044..902fdf4 100644 --- a/.zshrc +++ b/.zshrc @@ -639,7 +639,7 @@ __alias__() { # Zellij session manager if command_exists zellij; then za() { - if zellij list-sessions 2>/dev/null | grep -q .; then + if ! zellij list-sessions | tail -1 | grep -q EXITED; then echo "-- Zellij session active! | Connecting to existing session --" sleep 0.3 zellij attach