mirror of
https://github.com/romkatv/powerlevel10k.git
synced 2024-11-16 17:50:09 +00:00
Supressed error message for invalid acpi date (happens when disconnecting the power cable)
This commit is contained in:
parent
a637321d58
commit
b37090073c
1 changed files with 1 additions and 1 deletions
|
@ -412,7 +412,7 @@ prompt_battery() {
|
|||
if [[ $time_remaining =~ rate ]]; then
|
||||
local tstring="..."
|
||||
elif [[ $time_remaining =~ "[:digit:]+" ]]; then
|
||||
local tstring=${(f)$(date -u -d "$(echo $time_remaining)" +%k:%M)}
|
||||
local tstring=${(f)$(date -u -d "$(echo $time_remaining)" +%k:%M 2> /dev/null)}
|
||||
fi
|
||||
fi
|
||||
[[ -n $tstring ]] && local remain=" ($tstring)"
|
||||
|
|
Loading…
Reference in a new issue