Skip to content

I present you bato

Hi,

If like me you use a minimalist windows manager on a daily basis (no desktop environment) and your Linux runs on a laptop, this may interest you.

bato is a simple binary that sends desktop notifications on some battery events:

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

It works nicely with Dunst.

Configuration in Yaml.

Only one dependency: libnotify

Available in the AUR as a package.

โ€‹

Hope it will be useful, even a little bit :)

180 points21 comments
Open on Reddit
About this post
Posted
Archived
Score
180 ยท 98% up
Kind
Text
ID
jcdswd

Author

5
posts
36
comments
1
media
View profile

24 comments

looks super duper light -- how big's the bino and RAM usage?

19 points

How does one check the memory usage in bytes? The ps command only shows in percentage.

Binary is 536KB btw

9 points

Gnome-monitor or htop, and check ps --help.Cant give more help than that, on phone rn.

1 points

This seems perfect for me. This might very possibly just replace my crude hack in my statusbar to add battery notifications

9 points

Why yaml?

4 points

I am guessing because yaml is really easy to work with because

  1. It has a defined structure
  2. Compared to things like json it is by far way easier to manually write
22 points

Very convenient for the end user to write its configuration.

Why not ?

17 points

Could you add defaults so we don't need to write a configuration file?

4 points

Nope. Why ? Kiss.

2 points

So we don't have to write a configuration file ๐Ÿ˜…

I'd say that's a very nice tradeoff ๐Ÿ˜

I don't know about rust, but I assume that's just setting default parameters in the configuration class / object?

3 points

You should consider posting this in r/linux. I just checked it out and it looks awesome but haven't tried it yet. Gonna let you know after I do.

3 points

there is a way to install it on debian ?

1 points

You have nothing to "install".

Just pick the compiled binary in the releases section of the repository, make it executable and run it. Make sure you have libnotify installed with version >=0.7 and you should good to go :)

2 points
unknown author

Deleted before we saved it.

1 points

Keyboard shortcuts

Move and act

jork
Next / previous post or comment
Enteroro
Open the post
f
Open the media viewer
s
Save
h
Hide (the toast has Undo)
Tab
Right after an action: the toast's Undo
x
Collapse the comment
v
Next layout: cards, compact, grid

Go to

/
Search
gthenh
Home
gthena
All
gthens
Subreddits
gthenl
Library
?
This list
Esc
Close a menu or this list

In the viewer

โ†orโ†’
Previous / next file
โ†‘orโ†“
Previous / next post
korj
Previous / next post
Space
Play / pause
m
Mute
z
Zoom
s
Save
o
Open the post (on its own page: back to it)
Esc
Close

Keys do nothing while you type in a box.