Redirect std_err to /dev/null for the list of tmux session.

This commit is contained in:
gardouille 2015-08-28 18:31:15 +02:00
parent 9504c2290b
commit 30f6d6444f
1 changed files with 1 additions and 1 deletions

2
zlogin
View File

@ -56,7 +56,7 @@ fi
# List tmux sessions if tmux is available
if hash tmux; then
TMUX_SESSION=$(tmux ls|grep -- window)
TMUX_SESSION=$(tmux ls 2> /dev/null|grep -- window)
# If tmux session available and if not already inside a tmux
if [ ${TMUX_SESSION} ] && [ -z "${TMUX}" ]; then
printf '%b' "${MAGENTA}++++++++++++++++++++++++ ${WHITEB}Tmux session${RESET} ${MAGENTA}:++++++++++++++++++++++++${RESET}\n"