1
0
Fork 0
mirror of synced 2024-11-17 23:15:35 -05:00

fixed buggy battery detection logic, likely fixes #233

This commit is contained in:
Gregory Pakosz 2019-04-29 23:18:27 +02:00
parent 9fbde7b9b1
commit e631331281

View file

@ -237,6 +237,7 @@ run 'cut -c3- ~/.tmux.conf | sh -s _apply_configuration'
# }
#
# _battery() {
# count=0
# charge=0
# uname_s=$(uname -s)
# case "$uname_s" in
@ -301,7 +302,7 @@ run 'cut -c3- ~/.tmux.conf | sh -s _apply_configuration'
# done
# ;;
# esac
# charge=$(awk -v charge="$charge" -v count="$count" 'BEGIN { print charge / count }')
# [ "$count" -ne 0 ] && charge=$(awk -v charge="$charge" -v count="$count" 'BEGIN { print charge / count }')
# if [ "$charge" -eq 0 ]; then
# tmux set -ug '@battery_status' \;\
# set -ug '@battery_bar' \;\