diff --git a/home-manager/modules/zsh.nix b/home-manager/modules/zsh.nix index ac472c6..ca8f204 100644 --- a/home-manager/modules/zsh.nix +++ b/home-manager/modules/zsh.nix @@ -30,5 +30,12 @@ history.size = 10000; history.path = "${config.xdg.dataHome}/zsh/history"; + + initExtra = '' + # Start Tmux automatically if not already running + if [ -z "$TMUX" ]; then + tmux attach-session -t default || tmux new-session -s default + fi + ''; }; }