diff options
author | eug-vs <eugene@eug-vs.xyz> | 2021-09-21 10:56:14 +0300 |
---|---|---|
committer | eug-vs <eugene@eug-vs.xyz> | 2021-09-21 10:58:50 +0300 |
commit | 90b9522b15a692532d9b3f28acc417670144e3fa (patch) | |
tree | 546cccd97a5ee9c6069e09f616838be460b3bfed /raspberry/.zlogin | |
parent | 19498a2dd5aa8edb95c216482b63ed947a903bcc (diff) | |
download | dotfiles-90b9522b15a692532d9b3f28acc417670144e3fa.tar.gz |
feat(rpi): separate display and master sessions
Diffstat (limited to 'raspberry/.zlogin')
-rw-r--r-- | raspberry/.zlogin | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/raspberry/.zlogin b/raspberry/.zlogin index 227f78e..729b420 100644 --- a/raspberry/.zlogin +++ b/raspberry/.zlogin @@ -1 +1,8 @@ -[ -z "$TMUX" ] && tmux attach -t default || tmuxinator start default +if [ -n "$SSH_CONNECTION" ]; then + # If we are logged in via SSH, automatically attach to master session + [ -z "$TMUX" ] && (tmux attach -t master || tmux new -s master) +else + # If we are logged in directly (not via SSH) + # create the session which will be displayed on TV + tmuxinator start display +fi |