xss-lock: do not trigger a XRandR event

I need to fix that later...
This commit is contained in:
Vincent Bernat 2021-07-15 11:35:19 +02:00
parent c7365a8886
commit dfb7cb555e

View file

@ -25,10 +25,10 @@ case "$1" in
trap "systemctl --user kill -s CONT redshift@${display}.service" EXIT trap "systemctl --user kill -s CONT redshift@${display}.service" EXIT
trap 'echo notify: user activity; kill %% 2> /dev/null; exit 0' HUP # user activity trap 'echo notify: user activity; kill %% 2> /dev/null; exit 0' HUP # user activity
trap 'echo notify: locker started; kill %% 2> /dev/null; exit 0' TERM # locker started trap 'echo notify: locker started; kill %% 2> /dev/null; exit 0' TERM # locker started
outputs=($(xrandr --current | sed -n 's/\([^ ]*\) connected .*/\1/p')) # outputs=($(xrandr --current | sed -n 's/\([^ ]*\) connected .*/\1/p'))
for out in ${outputs[@]}; do # for out in ${outputs[@]}; do
xrandr --output $out --brightness 0.2 # xrandr --output $out --brightness 0.2
done # done
sleep infinity & sleep infinity &
wait wait
echo "notify: end" echo "notify: end"