aboutsummaryrefslogtreecommitdiff
path: root/.config/awesome
diff options
context:
space:
mode:
authorkj_sh6042025-09-07 23:09:05 -0400
committerkj_sh6042025-09-07 23:09:05 -0400
commit495604097aa46ca6155b8d079a5222420fdf7f45 (patch)
tree6014bb738ee04e469d6e20c007982fd8073421ac /.config/awesome
parent773c7dd2ab35e0b4ae3ef0f04b0c827a08ac2127 (diff)
refactor: add lock screen shortcut
Diffstat (limited to '.config/awesome')
-rw-r--r--.config/awesome/rc-4.3-3.lua6
-rw-r--r--.config/awesome/rc.lua6
2 files changed, 12 insertions, 0 deletions
diff --git a/.config/awesome/rc-4.3-3.lua b/.config/awesome/rc-4.3-3.lua
index c7d5f9c..73b6352 100644
--- a/.config/awesome/rc-4.3-3.lua
+++ b/.config/awesome/rc-4.3-3.lua
@@ -489,6 +489,12 @@ globalkeys = gears.table.join(
awful.key({ modkey }, "z", function () awful.spawn.easy_async_with_shell("boomer") end,
{description = "run boomer (zoomer application for Linux)", group = "launcher"}),
+ -- toggle lock screen, if available
+ awful.key({ modkey, "Shift" }, "l",
+ function() awful.spawn.easy_async_with_shell(
+ "command -v slock >/dev/null 2>&1 && slock || notify-send 'lock screen error:' 'slock not installed'") end,
+ { description = "lock the screen with slock", group = "awesome" }),
+
-- tiled client resizing
-- h,j,k,l binds
awful.key({ modkey }, "l", function() awful.tag.incmwfact(0.05) end,
diff --git a/.config/awesome/rc.lua b/.config/awesome/rc.lua
index 9c07b51..4d3a7d0 100644
--- a/.config/awesome/rc.lua
+++ b/.config/awesome/rc.lua
@@ -476,6 +476,12 @@ awful.keyboard.append_global_keybindings({
awful.key({ modkey }, "z", function() awful.spawn.easy_async_with_shell("boomer") end,
{ description = "run boomer (zoomer application for Linux)", group = "launcher" }),
+ -- toggle lock screen, if available
+ awful.key({ modkey, "Shift" }, "l",
+ function() awful.spawn.easy_async_with_shell(
+ "command -v slock >/dev/null 2>&1 && slock || notify-send 'lock screen error:' 'slock not installed'") end,
+ { description = "lock the screen with slock", group = "awesome" }),
+
-- tiled client resizing
-- h,j,k,l binds
awful.key({ modkey }, "l", function() awful.tag.incmwfact(0.05) end,