Stop idle_locker if disabled globally

This commit is contained in:
Willow Barraco
2023-12-17 10:00:03 +01:00
parent 97447367f6
commit 0535059f7d

View File

@@ -26,7 +26,9 @@ sxmo_jobs.sh stop periodic_blink
sxmo_jobs.sh stop periodic_wakelock_check
# Go down after 8 seconds of inactivity
if ! [ -e "$XDG_CACHE_HOME/sxmo/sxmo.noidle" ]; then
if [ -e "$XDG_CACHE_HOME/sxmo/sxmo.noidle" ]; then
sxmo_jobs.sh stop idle_locker
else
sxmo_jobs.sh start idle_locker sxmo_idle.sh -w \
timeout "${SXMO_LOCK_IDLE_TIME:-8}" "sxmo_state.sh down"
fi