From e6a83169943c909622a1e41439fb2ffb3a1bec31 Mon Sep 17 00:00:00 2001 From: "Adam T. Carpenter" Date: Thu, 2 Jul 2020 11:13:12 -0400 Subject: brought all locking, sleeping, etc. into autolocker --- autolocker.sh | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) (limited to 'autolocker.sh') diff --git a/autolocker.sh b/autolocker.sh index 5c79e23..9f6a894 100755 --- a/autolocker.sh +++ b/autolocker.sh @@ -1,10 +1,18 @@ #!/bin/sh -notifier="notify-send -t=10000 '10 seconds to lock...'" -locker="xautolock -notify 10 -time 10 -locker locker.sh" - if [ "$1" = "-d" ]; then - $locker -notifier "$notifier" + xautolock \ + -notify 10 \ + -time 10 \ + -locker "i3lock -n -f -c 000000 -i ~/.local/share/wallpapers/lock.png; sleep 0.2" \ + -notifier "notify-send -t=10000 '10 seconds to lock...'" else - $locker -detectsleep -killtime 10 -killer "sleeper.sh" -notifier "$notifier" + xautolock \ + -detectsleep \ + -killtime 10 \ + -killer "acpiconf -s3" \ + -notify 10 \ + -time 10 \ + -locker "i3lock -n -f -c 000000 -i ~/.local/share/wallpapers/lock.png; sleep 0.2" \ + -notifier "notify-send -t=10000 '10 seconds to lock...'" fi -- cgit v1.2.3