summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
Diffstat (limited to 'bin')
-rwxr-xr-xbin/statusbar5
1 files changed, 2 insertions, 3 deletions
diff --git a/bin/statusbar b/bin/statusbar
index 66f0b49..bc74cae 100755
--- a/bin/statusbar
+++ b/bin/statusbar
@@ -32,12 +32,12 @@ sub network {
sub brightness {
my @brightness = split(/,/, `brightnessctl -m`);
- return span('#eed49f', $brightness[3]);
+ return span('#eed49f', ' ' . $brightness[3]);
}
sub battery {
open my $cap_file, '<', '/sys/class/power_supply/BAT0/capacity' or die;
- open my $status_file, '<', '/sys/class/power_supply/BAT0/capacity' or die;
+ open my $status_file, '<', '/sys/class/power_supply/BAT0/status' or die;
chomp(my $capacity = <$cap_file>);
chomp(my $status = <$status_file>);
close $status_file;
@@ -68,4 +68,3 @@ while (1) {
system('somebar', '-c', 'status', $status);
sleep 1;
}
-