-# Find an existing screen locker.
-for locker in xtrlock ''; do
- if installed "$locker"; then
- break
- fi
-done
-if test -z "$locker"; then
- echo 'No screen locker found!' | notify 60
-fi
-# Lock the screen. The sleep is necessary to allow xtrlock to grab the
-# keyboard input.
-hc keybind $mod-z spawn sh -c "sleep 1 && exec $locker"