mirror of
https://github.com/romkatv/powerlevel10k.git
synced 2024-12-24 16:11:57 +00:00
don't assume that zero size of a file in /sys actually means it's empty
This commit is contained in:
parent
bd921485fc
commit
56060f0bc1
1 changed files with 1 additions and 1 deletions
|
@ -1252,7 +1252,7 @@ _p9k_prompt_battery_init() {
|
|||
return
|
||||
fi
|
||||
if [[ $_p9k_os != (Linux|Android) ||
|
||||
-z /sys/class/power_supply/(BAT*|battery)/(energy_full|charge_full|charge_counter)(#qL+0N) ]]; then
|
||||
-z /sys/class/power_supply/(BAT*|battery)/(energy_full|charge_full|charge_counter)(#qN) ]]; then
|
||||
typeset -g "_p9k__segment_cond_${_p9k__prompt_side}[_p9k__segment_index]"='${:-}'
|
||||
fi
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue