~ruther/nixos-config

ref: 2ee75c629cdb30b994e36c9abff4e82621e00c73 nixos-config/modules/desktop/qtile/config/brightness.sh -rw-r--r-- 347 bytes
2ee75c62 — Frantisek Bohacek feat(laptop): add brightness program and adjustment in qtile 1 year, 6 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#!/usr/bin/env sh

function send_notification() {
    brightness=$(printf "%.0f\n" $(brillo -G))
    dunstify -a "brightness" -u low -r 9991 -h int:value:"$brightness" -i "brightness-$1" "Brightness: $brightness %"
}

case $1 in
    up)
        brillo -A 5 -q
        ;;
    down)
        brillo -U 5 -q -c 2
        ;;
esac

send_notification $1
Do not follow this link