From d0f19fe55e1dc7fa62740d29e6b1396d30573b8d Mon Sep 17 00:00:00 2001 From: Léana 江 Date: Mon, 22 Jun 2026 21:54:18 +0200 Subject: document XMOBAR_BATT_LEFT variable --- doc/plugins.org | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'doc/plugins.org') diff --git a/doc/plugins.org b/doc/plugins.org index 4d14771..ecc9507 100644 --- a/doc/plugins.org +++ b/doc/plugins.org @@ -306,8 +306,8 @@ "--", "-O", "On - ", "-i", "", "-L", "-15", "-H", "-5", "-l", "red", "-m", "blue", "-h", "green", - "-a", "notify-once \"xmobar\" -u critical 'Battery running out!!'", - "-A", "3"] + "-a", "notify-once \"xmobar\" -u critical 'Battery running out!!' \"$XMOBAR_BATT_LEFT% Remains\"", + "-A", "6"] 600 #+end_src @@ -318,6 +318,9 @@ We are also telling the monitor to execute the unix command =notify-once= when the percentage left in the battery reaches 6%. + =XMOBAR_BATT_LEFT= environment variable is made available to the program being called. + You can use it to make the alert message more informative. It is an integer between 0 and 100. + =notify-once= is a bash wrapper script provided with the =xmobar= package. =xmobar= will run the notification command according to the refresh period, this has the effect of spamming the notification tray if calling =notify-send= directly. -- cgit v1.2.3