diff options
author | Florian Pritz <bluewind@xinu.at> | 2014-09-30 16:29:16 +0200 |
---|---|---|
committer | Florian Pritz <bluewind@xinu.at> | 2014-09-30 16:29:16 +0200 |
commit | f395da5d7a83523fa4ece83749bc963e1eca86be (patch) | |
tree | cf887ea69b0c0a402f3b893eb8bc3fbe26dc44b1 /.zprofile | |
parent | 3de4a9ecda2b892fe14fde65c75fdfd1b82e479c (diff) | |
download | dotfiles-f395da5d7a83523fa4ece83749bc963e1eca86be.tar.gz dotfiles-f395da5d7a83523fa4ece83749bc963e1eca86be.tar.xz |
zprofile: don't start screen inside tmux
Signed-off-by: Florian Pritz <bluewind@xinu.at>
Diffstat (limited to '.zprofile')
-rw-r--r-- | .zprofile | 14 |
1 files changed, 8 insertions, 6 deletions
@@ -9,12 +9,14 @@ if tty -s && [[ -z $DISPLAY ]]; then fi fi - if type screen &>/dev/null && [[ -e ~/.screenrc-2 ]]; then - screenname=$(screen -list | grep "screen-sh-2") - if [ ! "$screenname" ]; then - exec screen -S "screen-sh-2" -c ~/.screenrc-2 - elif echo $screenname | grep -q "Detached"; then - exec screen -r screen-sh-2 + if [[ -z "$TMUX" ]]; then + if type screen &>/dev/null && [[ -e ~/.screenrc-2 ]]; then + screenname=$(screen -list | grep "screen-sh-2") + if [ ! "$screenname" ]; then + exec screen -S "screen-sh-2" -c ~/.screenrc-2 + elif echo $screenname | grep -q "Detached"; then + exec screen -r screen-sh-2 + fi fi fi fi |