---- # Increase backlight "myxbacklight -inc 10" XF86MonBrightnessUp # Decrease backlight "myxbacklight -dec 10" XF86MonBrightnessDown ---- and, myxbacklight (which i'm not offering as a model of great programming!) looks as follows: ---- #!/bin/sh # does xbacklight, then brags about it x=$(xbacklight -get | sed s/[.].*//) if [[ "$1" == "-dec" ]]; then if [[ $(($x-$2)) -lt 10 ]]; then set -- -set $(($x-1)) fi elif [[ "$1" == "-inc" ]]; then if [[ $x -lt 10 ]]; then set -- -set $(($x+1)) fi fi xbacklight $* myid=$(dc -e "16 i $(echo $0 | sha1sum 2>&1 | sed 's/\(^.....\).*$/\1/' | tr '[:lower:]' '[:upper:]') p") dunstify --replace=${myid} "Brightness: $(dc -e 3k$(xbacklight)\ .5+0k1/p) percent" ---- cheers, GregReceived on Tue Apr 14 2020 - 01:18:44 CEST
This archive was generated by hypermail 2.3.0 : Tue Apr 14 2020 - 01:24:35 CEST