From 2bf44995e77d019a3114011ec390c805083fb0dc Mon Sep 17 00:00:00 2001 From: Samir Benmendil Date: Sat, 11 Mar 2023 23:43:16 +0000 Subject: [PATCH] awesome: add binding for pasting primary selection --- awesome/bindings.lua | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/awesome/bindings.lua b/awesome/bindings.lua index e53b301..ae2ebaf 100644 --- a/awesome/bindings.lua +++ b/awesome/bindings.lua @@ -144,7 +144,12 @@ globalkeys = gears.table.join(globalkeys, -- VimWiki awful.key({ modkey }, "i", function () utils.spawn_terminal("vim -c 'call vimwiki#base#goto_index(v:count1)'", { instance = "vimwiki"}) - end) + end), + -- clipboard + -- requires a little sleep before simulating shift+Insert, otherwise I + -- believe the focus is still on awful and not the current window + awful.key({ modkey }, "\\", function () awful.spawn('xdotool sleep 0.2 key --clearmodifiers shift+Insert') end, + {description = "paste primary selection", group = "awesome"}) ) -- Client keys {{{1 -- 2.48.1