Open zefr0x opened 1 year ago
I don't know how to set suspend, but you can try the following to set locks and the screen turn off. A simple style may be like this:
xset dpms 0 0 60 // wait 60s to turn off screen
xset s 30 // wait 30s to lock device
xss-lock -l -- xsecurelock &
I don't have problems with this part.
xset dpms 0 0 60 // wait 60s to turn off screen
I'm already using this to trigger xss-lock.
xset s 30 // wait 30s to lock device
This will just dim my screen using /usr/lib/xsecurelock/dimmer
preparing to it's lock, xsecurelock will handle things aftart that.
My problem is with xsecurelock's screen saver part. After locking the screen it should start working as a timer to suspend my device after some time, and be killed with any activity (e.g. keyboard clicked, mouse moved).
But what is happening with me is that xsecurelock's screen saver will not work directly when my screen is locked, it will only work if I did an activity after locking my screen (without unlocking it) then keep it idle again.
I want xsecurelock's screen saver to work directly after locking my screen.
The second exec of saver_sleep_after_time is not going to get executed because the shell will get replace with the sleep command.
I would also be interested in this state diagram.
@zefr0x Keep "xss-lock" running and run "xautolock". like this:
xss-lock -l -- env XSECURELOCK_BLANK_TIMEOUT=10 xsecurelock
xautolock -time 60 -locker "systemctl suspend" -detectsleep
(xautolock seems to have a timer limit of up to 1 hour)
I'm trying to do this:
My config: scripts/lock.sh
My screen saver script: scripts/saver_sleep_after_time
My
xss-lock
launch: .config/i3/configWhat I concluded is happening with me is that as soon as
XSECURELOCK_BLANK_TIMEOUT
ends my screen will be turned off, but also thesaver_sleep_after_time
script will stop working, and the 2h timer for suspending will not work.If I disabled
XSECURELOCK_BLANK_TIMEOUT
my screen will be always working which is a problem too.Is there any solution for that?