From 0e4dc62fd5385879ed7844e5471ab190cb9858a7 Mon Sep 17 00:00:00 2001 From: thomasba Date: Wed, 19 May 2021 22:14:31 +0200 Subject: [PATCH] Change file open commands --- zsh/commands | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/zsh/commands b/zsh/commands index 3c93985..ff0a9aa 100644 --- a/zsh/commands +++ b/zsh/commands @@ -27,7 +27,8 @@ whothefuckisusingport() { # functions function tm() { - NUM="$(\tmux ls 2>/dev/null|wc -l)" + OUT="$(\tmux ls 2>/dev/null)" + NUM="$(echo "$OUT" | wc -l)" if [ "$NUM" -eq 0 ] ; then \tmux -2 elif [ "$NUM" -eq 1 ] ; then