You are not logged in.

#1 2015-07-30 13:59:58

Median
Member
Registered: 2011-06-03
Posts: 60

Time delay starting xlock when resuming laptop

I've done so that xlock starts after I've resumed my laptop with the following service:

[Unit]
Description=User resume actions
After=suspend.target

[Service]
User=%I
Type=simple
Environment=DISPLAY=:0
ExecStart=/usr/bin/xlock

[Install]
WantedBy=suspend.target

Everything works fine, with the exception that xlock doesn't start until 2 seconds after resuming. Is there a way to start xlock instantly? Are there any other options to lock my screen after resuming? Starting before suspend doesn't work as it will just prevent the laptop from suspending. Thanks!

Offline

Board footer

Powered by FluxBB