aboutsummaryrefslogtreecommitdiff
path: root/powerlevel9k.zsh-theme
diff options
context:
space:
mode:
authorrjorgenson <rjorgenson@gmail.com>2016-11-21 19:51:27 +0300
committerrjorgenson <rjorgenson@gmail.com>2016-11-21 19:51:27 +0300
commit6d2681d36a5ea0bcd9db889182e7ca1ba72d27ed (patch)
treefbb94055e9aae188ef72bbc727f7870121566990 /powerlevel9k.zsh-theme
parentb81084100f99f6b79b772a46a6d5a561e82d8743 (diff)
fixed regex to determine time remaining on linux for battery segment
Diffstat (limited to 'powerlevel9k.zsh-theme')
-rwxr-xr-xpowerlevel9k.zsh-theme2
1 files changed, 1 insertions, 1 deletions
diff --git a/powerlevel9k.zsh-theme b/powerlevel9k.zsh-theme
index d573f6f9..321c262d 100755
--- a/powerlevel9k.zsh-theme
+++ b/powerlevel9k.zsh-theme
@@ -391,7 +391,7 @@ prompt_battery() {
local time_remaining=$(acpi | awk '{ print $5 }')
if [[ $time_remaining =~ rate ]]; then
local tstring="..."
- elif [[ $time_remaining =~ "[:digit:]+" ]]; then
+ elif [[ $time_remaining =~ "[[:digit:]]+" ]]; then
local tstring=${(f)$(date -u -d "$(echo $time_remaining)" +%k:%M)}
fi
fi