aboutsummaryrefslogtreecommitdiff
path: root/.config
diff options
context:
space:
mode:
authorsrdusr <trevorgray@srdusr.com>2023-10-17 21:13:14 +0200
committersrdusr <trevorgray@srdusr.com>2023-10-17 21:13:14 +0200
commitedf95aa4154a8ff24e5273231587649d77e02f62 (patch)
treeeb57536882bf244dd642e934df0a3ead93ff700f /.config
parentdddb25fecf7059a9b4bb1f24dab66b31de3aa178 (diff)
downloaddotfiles-edf95aa4154a8ff24e5273231587649d77e02f62.tar.gz
dotfiles-edf95aa4154a8ff24e5273231587649d77e02f62.zip
Tmux default session
Diffstat (limited to '.config')
-rw-r--r--.config/zsh/.zshrc5
1 files changed, 5 insertions, 0 deletions
diff --git a/.config/zsh/.zshrc b/.config/zsh/.zshrc
index 4713e53..a891772 100644
--- a/.config/zsh/.zshrc
+++ b/.config/zsh/.zshrc
@@ -15,6 +15,11 @@ else
export KEYTIMEOUT=15
fi
+# Tmux default session
+if command -v tmux &> /dev/null && [ -n "$PS1" ] && [[ ! "$TERM" =~ screen ]] && [[ ! "$TERM" =~ tmux ]] && [ -z "$TMUX" ]; then
+ tmux a -t tmux || exec tmux new -s tmux && exit;
+fi
+
# Enable various options
setopt interactive_comments beep extendedglob nomatch notify completeinword prompt_subst