From 9a86fb2c4e3b298dc0eeeb2dec77fc7b70e80248 Mon Sep 17 00:00:00 2001 From: 10sr <8slashes+git@gmail.com> Date: Thu, 20 Dec 2012 13:32:48 +0900 Subject: [PATCH] do not show battery status when 100% --- bashrc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bashrc b/bashrc index 041743d..be7059e 100755 --- a/bashrc +++ b/bashrc @@ -678,7 +678,8 @@ __my_ps1_bttry(){ if test -z "$DISPLAY" && ! iswindows then test -f $bst && local bstr="$(cat $bst)" - test -n "$bstr" && echo "[Battery:$bstr]" + test -n "$bstr" && ! echo $bstr | grep 100 >/dev/null 2>&1 && \ + echo "[Battery:$bstr]" __my_battery_status %s >$bst & fi return $last