Skip to content

Latest commit

History

59 Commits

Folders and files

NameName
Last commit message
Last commit date

Repository files navigation

batobato

bato

A program to send battery level notifications

bato

features - prerequisite - install - configuration - usage - license

Features

Tiny configuration in toml.

Desktop notification:

  • level full
  • level low
  • level critical
  • charging
  • discharging

Prerequisite

A desktop notification server, like Dunst

Install

Configuration

By default, bato looks for the config file ~/.config/bato/bato.toml (XDG dir spec).
To use a custom file, run with the --config flag.
If the config file is not found or invalid, bato prints an error and exits.

All config options are detailed here.

Tip

Keep tick_rate low to save battery. Bato uses udev to listen to AC events,
so it notifies instantly on charger plug/unplug.

Example:

tick_rate = 30# seccritical_level = 5low_level = 20full_design = true
[charging]
summary = "Battery"body = "Charging"icon = "battery-good-charging"
[discharging]
summary = "Battery"body = "Discharging"icon = "battery-good"
[full]
summary = "Battery"body = "Full"icon = "battery-full"
[low]
summary = "Battery"body = "Low"icon = "battery-low"
[critical]
summary = "Battery"body = "Critical!"icon = "battery-caution"urgency = "critical"

Usage

Run bato via your window manager or desktop environment autostart system

Example with XMonad

myStartupHook =do
spawnOnce "dunst"
spawnOnce "bato -lfile"

Tip

By default bato logs to stdout. To log into a file run with -lfile. Logs are located in ~/.cache/bato/

bato -h

License

Mozilla Public License 2.0

About

A program to send battery level notifications

Topics

Resources

Stars

44 stars

Watchers

1 watching

Forks

Releases

Sponsor this project

Contributors

Languages