From 34835335c7b4ba4ddf829510725793c5311ad2f6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Olivier=20Mengu=C3=A9?= Date: Wed, 4 Dec 2013 23:38:20 +0100 Subject: [PATCH] screen: stricter matching in detached sessions counting --- liquidprompt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/liquidprompt b/liquidprompt index 2714952..d538008 100755 --- a/liquidprompt +++ b/liquidprompt @@ -665,7 +665,7 @@ _lp_jobcount_color() local running=$(( $(jobs -r | wc -l) )) local stopped=$(( $(jobs -s | wc -l) )) - local n_screen=$(screen -ls 2> /dev/null | grep -c '[Dd]etach[^)]*)$') + local n_screen=$(screen -ls 2> /dev/null | grep -c '([Dd]etach[^)]*)$') local n_tmux=$(tmux list-sessions 2> /dev/null | grep -cv attached) local detached=$(( $n_screen + $n_tmux )) local m_detached="d"