D-Nice / batteryd-runit

Runit service and shell script to monitor, notify, and suspend on battery level thresholds

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

batteryd

Runit service for monitoring your battery levels if discharging, sending notifications and suspending when below configured thresholds.

Requirements

  • X Session
  • libnotify
  • A battery ;P

Install

mkdir -p /etc/sv/batteryd
cp -r ./* /etc/sv/batteryd

ensure root is owner and group...

Configuration

Check conf file for available and settable configurables.

Notes

Should be reusable even if you don't have a runit specific system

If you're missing the notifications lib, you can disable the strict exit code checking by commenting out set -e.

May also contain useful parts, such as a portable way for notifying all users with active DISPLAY.

About

Runit service and shell script to monitor, notify, and suspend on battery level thresholds

License:MIT License


Languages

Language:Shell 100.0%