lock: use xss-lock instead of xautolock

xss-lock features nice integration with standard X screensaver
feature which makes it easy to trigger it or to disable it. Moreover, it
also has some logind integration to lock screen before suspend.
This commit is contained in:
Vincent Bernat 2014-09-12 14:52:36 +02:00
parent 2c19d0021f
commit 097e076694
7 changed files with 48 additions and 37 deletions

View file

@ -1,15 +1,7 @@
-- Lockscreen
local icons = loadrc("icons", "vbe/icons")
xrun("xautolock",
awful.util.getdir("config") ..
"/bin/xautolock " ..
icons.lookup({name = "system-lock-screen", type = "actions" }))
local lock = function()
awful.util.spawn(awful.util.getdir("config") ..
"/bin/locker", false)
os.execute("xset s activate")
end
config.keys.global = awful.util.table.join(
@ -17,5 +9,6 @@ config.keys.global = awful.util.table.join(
awful.key({}, "XF86ScreenSaver", lock),
awful.key({ modkey, }, "Delete", lock))
-- Configure DPMS
os.execute("xset dpms 360 720 1200")
-- Configure xss-lock
os.execute(awful.util.spawn(awful.util.getdir("config") ..
"/bin/xss-lock start"))