1
0
Fork 0
dotfiles/.config/eww/scripts/powernotify
Lucas Sta Maria a1d3d54b0f
fix(eww): add power information notification
Signed-off-by: Lucas Sta Maria <lucas@priime.dev>
2024-01-31 14:44:36 -05:00

7 lines
199 B
Bash
Executable file

#!/usr/bin/env bash
msg=$(upower -i /org/freedesktop/UPower/devices/battery_BAT0 | \
grep -E "state|time to|percentage" | \
awk '{$1=$1};1')
notify-send -t 3000 "Battery Status" "$msg"