Skip to content

Commit

Permalink
Revert "battery: charging => success color and no level"
Browse files Browse the repository at this point in the history
This reverts commit 421c686.
  • Loading branch information
sunaku committed Jan 19, 2012
1 parent e93a7be commit b71c0c3
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions status/battery.yaml
Expand Up @@ -7,16 +7,16 @@ status:
label: |
device, status = `acpi -b | fgrep ' #{@id}:'`.chomp.split(/: */, 2)
status, level, time = status.split(/, */)
charging = `acpi -a` =~ /on-line/
time &&= time[/[0:]*(\S+)/, 1]
color = charging ? :success :
icon = `acpi -a` =~ /on-line/ ? "\u279A" : "\u2798"
color =
case [level.to_f, @low, @critical].max
when @critical then :error
when @low then :notice
end
[color, "\u26A1", (level unless charging), time]
[color, "\u26A1", level, icon, time]
control:
action:
Expand Down

0 comments on commit b71c0c3

Please sign in to comment.