comparison .zshrc @ 286:c7e8311eb2ba

zshrc: suppress stderr from tmux tmux prints some stderr of 'tmux ls' would show nothing.
author Augie Fackler <raf@durin42.com>
date Thu, 03 May 2012 18:06:26 -0500
parents c65cc71d7ba1
children e37b00236907
comparison
equal deleted inserted replaced
285:d77b2e253e99 286:c7e8311eb2ba
19 export SHOWED_SCREEN_MESSAGE="true" 19 export SHOWED_SCREEN_MESSAGE="true"
20 fi 20 fi
21 21
22 if [ ! "$SHOWED_TMUX_MESSAGE" = "true" ]; then 22 if [ ! "$SHOWED_TMUX_MESSAGE" = "true" ]; then
23 if which tmux > /dev/null; then 23 if which tmux > /dev/null; then
24 detached_screens=$(tmux ls | grep -v attached) 24 detached_screens=$(tmux ls 2> /dev/null | grep -v attached)
25 if [ ! -z "$detached_screens" ]; then 25 if [ ! -z "$detached_screens" ]; then
26 echo "+-----------------------------------------------------------+" 26 echo "+-----------------------------------------------------------+"
27 echo "| Detached tmux sessions are available: |" 27 echo "| Detached tmux sessions are available: |"
28 echo "$detached_screens" 28 echo "$detached_screens"
29 echo "+-----------------------------------------------------------+" 29 echo "+-----------------------------------------------------------+"