diff options
Diffstat (limited to '.zprofile')
-rw-r--r-- | .zprofile | 13 |
1 files changed, 7 insertions, 6 deletions
@@ -1,7 +1,8 @@ -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 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 - |