if sensor is less than 3, sets to 1. if xfce brightness bug puts actual_brightness to 0, it will goes to 1 with less than 3 in anbient or more with greater than 3 anbient.. add service in :"/etc/systemd/system/" to auto start and auto restart if broken in e.g. suspend. Works even in the greeter.
25 lines
457 B
Desktop File
25 lines
457 B
Desktop File
[Unit]
|
|
|
|
Description=roda autobrightness com 1% de processamento
|
|
After=multi-user.target
|
|
After=graphical.target
|
|
After=basic.target
|
|
After=sysinit.target
|
|
After=system.slice
|
|
After=systemd-journald.socket
|
|
After=initrd-switch-root.service
|
|
After=iio-sensor-proxy.service
|
|
|
|
|
|
|
|
[Service]
|
|
ExecStartPre=/bin/bash -c "sleep 5"
|
|
ExecStart=/bin/bash -c "exec /etc/luztecla/autobrightness.sh"
|
|
|
|
|
|
Restart=always
|
|
|
|
[Install]
|
|
|
|
WantedBy=graphical.target
|
|
WantedBy=multi-user.target
|