mirror of
https://github.com/lcpz/awesome-copycats.git
synced 2025-01-11 02:08:08 +00:00
Moved tag bindings to settings/binds.lua
This commit is contained in:
parent
00c993dcf3
commit
3dda0e3e99
|
@ -293,7 +293,7 @@ end
|
|||
require("settings.binds")
|
||||
|
||||
-- {{{ Key bindings
|
||||
globalkeys = awful.util.table.join(
|
||||
globalkeys = awful.util.table.join(globalkeys,
|
||||
-- Take a screenshot
|
||||
-- https://github.com/copycat-killer/dots/blob/master/bin/screenshot
|
||||
awful.key({ altkey }, "p", function() os.execute("screenshot") end),
|
||||
|
@ -476,43 +476,6 @@ clientkeys = awful.util.table.join(
|
|||
end)
|
||||
)
|
||||
|
||||
-- Bind all key numbers to tags.
|
||||
-- Be careful: we use keycodes to make it works on any keyboard layout.
|
||||
-- This should map on the top row of your keyboard, usually 1 to 9.
|
||||
for i = 1, 9 do
|
||||
globalkeys = awful.util.table.join(globalkeys,
|
||||
awful.key({ modkey }, "#" .. i + 9,
|
||||
function ()
|
||||
local screen = mouse.screen
|
||||
local tag = awful.tag.gettags(screen)[i]
|
||||
if tag then
|
||||
awful.tag.viewonly(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Control" }, "#" .. i + 9,
|
||||
function ()
|
||||
local screen = mouse.screen
|
||||
local tag = awful.tag.gettags(screen)[i]
|
||||
if tag then
|
||||
awful.tag.viewtoggle(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Shift" }, "#" .. i + 9,
|
||||
function ()
|
||||
local tag = awful.tag.gettags(client.focus.screen)[i]
|
||||
if client.focus and tag then
|
||||
awful.client.movetotag(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Control", "Shift" }, "#" .. i + 9,
|
||||
function ()
|
||||
local tag = awful.tag.gettags(client.focus.screen)[i]
|
||||
if client.focus and tag then
|
||||
awful.client.toggletag(tag)
|
||||
end
|
||||
end))
|
||||
end
|
||||
|
||||
clientbuttons = awful.util.table.join(
|
||||
awful.button({ }, 1, function (c) client.focus = c; c:raise() end),
|
||||
awful.button({ modkey }, 1, awful.mouse.client.move),
|
||||
|
|
|
@ -343,7 +343,7 @@ end
|
|||
require("settings.binds")
|
||||
|
||||
-- {{{ Key bindings
|
||||
globalkeys = awful.util.table.join(
|
||||
globalkeys = awful.util.table.join(globalkeys,
|
||||
-- Take a screenshot
|
||||
-- https://github.com/copycat-killer/dots/blob/master/bin/screenshot
|
||||
awful.key({ altkey }, "p", function() os.execute("screenshot") end),
|
||||
|
@ -530,43 +530,6 @@ clientkeys = awful.util.table.join(
|
|||
end)
|
||||
)
|
||||
|
||||
-- Bind all key numbers to tags.
|
||||
-- Be careful: we use keycodes to make it works on any keyboard layout.
|
||||
-- This should map on the top row of your keyboard, usually 1 to 9.
|
||||
for i = 1, 9 do
|
||||
globalkeys = awful.util.table.join(globalkeys,
|
||||
awful.key({ modkey }, "#" .. i + 9,
|
||||
function ()
|
||||
local screen = mouse.screen
|
||||
local tag = awful.tag.gettags(screen)[i]
|
||||
if tag then
|
||||
awful.tag.viewonly(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Control" }, "#" .. i + 9,
|
||||
function ()
|
||||
local screen = mouse.screen
|
||||
local tag = awful.tag.gettags(screen)[i]
|
||||
if tag then
|
||||
awful.tag.viewtoggle(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Shift" }, "#" .. i + 9,
|
||||
function ()
|
||||
local tag = awful.tag.gettags(client.focus.screen)[i]
|
||||
if client.focus and tag then
|
||||
awful.client.movetotag(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Control", "Shift" }, "#" .. i + 9,
|
||||
function ()
|
||||
local tag = awful.tag.gettags(client.focus.screen)[i]
|
||||
if client.focus and tag then
|
||||
awful.client.toggletag(tag)
|
||||
end
|
||||
end))
|
||||
end
|
||||
|
||||
clientbuttons = awful.util.table.join(
|
||||
awful.button({ }, 1, function (c) client.focus = c; c:raise() end),
|
||||
awful.button({ modkey }, 1, awful.mouse.client.move),
|
||||
|
|
|
@ -293,7 +293,7 @@ end
|
|||
require("settings.binds")
|
||||
|
||||
-- {{{ Key bindings
|
||||
globalkeys = awful.util.table.join(
|
||||
globalkeys = awful.util.table.join(globalkeys,
|
||||
-- Take a screenshot
|
||||
-- https://github.com/copycat-killer/dots/blob/master/bin/screenshot
|
||||
awful.key({ altkey }, "p", function() os.execute("screenshot") end),
|
||||
|
@ -476,43 +476,6 @@ clientkeys = awful.util.table.join(
|
|||
end)
|
||||
)
|
||||
|
||||
-- Bind all key numbers to tags.
|
||||
-- Be careful: we use keycodes to make it works on any keyboard layout.
|
||||
-- This should map on the top row of your keyboard, usually 1 to 9.
|
||||
for i = 1, 9 do
|
||||
globalkeys = awful.util.table.join(globalkeys,
|
||||
awful.key({ modkey }, "#" .. i + 9,
|
||||
function ()
|
||||
local screen = mouse.screen
|
||||
local tag = awful.tag.gettags(screen)[i]
|
||||
if tag then
|
||||
awful.tag.viewonly(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Control" }, "#" .. i + 9,
|
||||
function ()
|
||||
local screen = mouse.screen
|
||||
local tag = awful.tag.gettags(screen)[i]
|
||||
if tag then
|
||||
awful.tag.viewtoggle(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Shift" }, "#" .. i + 9,
|
||||
function ()
|
||||
local tag = awful.tag.gettags(client.focus.screen)[i]
|
||||
if client.focus and tag then
|
||||
awful.client.movetotag(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Control", "Shift" }, "#" .. i + 9,
|
||||
function ()
|
||||
local tag = awful.tag.gettags(client.focus.screen)[i]
|
||||
if client.focus and tag then
|
||||
awful.client.toggletag(tag)
|
||||
end
|
||||
end))
|
||||
end
|
||||
|
||||
clientbuttons = awful.util.table.join(
|
||||
awful.button({ }, 1, function (c) client.focus = c; c:raise() end),
|
||||
awful.button({ modkey }, 1, awful.mouse.client.move),
|
||||
|
|
39
rc.lua.holo
39
rc.lua.holo
|
@ -428,7 +428,7 @@ end
|
|||
require("settings.binds")
|
||||
|
||||
-- {{{ Key bindings
|
||||
globalkeys = awful.util.table.join(
|
||||
globalkeys = awful.util.table.join(globalkeys,
|
||||
-- Take a screenshot
|
||||
-- https://github.com/copycat-killer/dots/blob/master/bin/screenshot
|
||||
awful.key({ altkey }, "p", function() os.execute("screenshot") end),
|
||||
|
@ -611,43 +611,6 @@ clientkeys = awful.util.table.join(
|
|||
end)
|
||||
)
|
||||
|
||||
-- Bind all key numbers to tags.
|
||||
-- Be careful: we use keycodes to make it works on any keyboard layout.
|
||||
-- This should map on the top row of your keyboard, usually 1 to 9.
|
||||
for i = 1, 9 do
|
||||
globalkeys = awful.util.table.join(globalkeys,
|
||||
awful.key({ modkey }, "#" .. i + 9,
|
||||
function ()
|
||||
local screen = mouse.screen
|
||||
local tag = awful.tag.gettags(screen)[i]
|
||||
if tag then
|
||||
awful.tag.viewonly(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Control" }, "#" .. i + 9,
|
||||
function ()
|
||||
local screen = mouse.screen
|
||||
local tag = awful.tag.gettags(screen)[i]
|
||||
if tag then
|
||||
awful.tag.viewtoggle(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Shift" }, "#" .. i + 9,
|
||||
function ()
|
||||
local tag = awful.tag.gettags(client.focus.screen)[i]
|
||||
if client.focus and tag then
|
||||
awful.client.movetotag(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Control", "Shift" }, "#" .. i + 9,
|
||||
function ()
|
||||
local tag = awful.tag.gettags(client.focus.screen)[i]
|
||||
if client.focus and tag then
|
||||
awful.client.toggletag(tag)
|
||||
end
|
||||
end))
|
||||
end
|
||||
|
||||
clientbuttons = awful.util.table.join(
|
||||
awful.button({ }, 1, function (c) client.focus = c; c:raise() end),
|
||||
awful.button({ modkey }, 1, awful.mouse.client.move),
|
||||
|
|
|
@ -360,7 +360,7 @@ end
|
|||
require("settings.binds")
|
||||
|
||||
-- {{{ Key bindings
|
||||
globalkeys = awful.util.table.join(
|
||||
globalkeys = awful.util.table.join(globalkeys,
|
||||
-- Take a screenshot
|
||||
-- https://github.com/copycat-killer/dots/blob/master/bin/screenshot
|
||||
awful.key({ altkey }, "p", function() os.execute("screenshot") end),
|
||||
|
@ -540,43 +540,6 @@ clientkeys = awful.util.table.join(
|
|||
end)
|
||||
)
|
||||
|
||||
-- Bind all key numbers to tags.
|
||||
-- Be careful: we use keycodes to make it works on any keyboard layout.
|
||||
-- This should map on the top row of your keyboard, usually 1 to 9.
|
||||
for i = 1, 9 do
|
||||
globalkeys = awful.util.table.join(globalkeys,
|
||||
awful.key({ modkey }, "#" .. i + 9,
|
||||
function ()
|
||||
local screen = mouse.screen
|
||||
local tag = awful.tag.gettags(screen)[i]
|
||||
if tag then
|
||||
awful.tag.viewonly(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Control" }, "#" .. i + 9,
|
||||
function ()
|
||||
local screen = mouse.screen
|
||||
local tag = awful.tag.gettags(screen)[i]
|
||||
if tag then
|
||||
awful.tag.viewtoggle(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Shift" }, "#" .. i + 9,
|
||||
function ()
|
||||
local tag = awful.tag.gettags(client.focus.screen)[i]
|
||||
if client.focus and tag then
|
||||
awful.client.movetotag(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Control", "Shift" }, "#" .. i + 9,
|
||||
function ()
|
||||
local tag = awful.tag.gettags(client.focus.screen)[i]
|
||||
if client.focus and tag then
|
||||
awful.client.toggletag(tag)
|
||||
end
|
||||
end))
|
||||
end
|
||||
|
||||
clientbuttons = awful.util.table.join(
|
||||
awful.button({ }, 1, function (c) client.focus = c; c:raise() end),
|
||||
awful.button({ modkey }, 1, awful.mouse.client.move),
|
||||
|
|
|
@ -351,7 +351,7 @@ end
|
|||
require("settings.binds")
|
||||
|
||||
-- {{{ Key bindings
|
||||
globalkeys = awful.util.table.join(
|
||||
globalkeys = awful.util.table.join(globalkeys,
|
||||
-- Take a screenshot
|
||||
-- https://github.com/copycat-killer/dots/blob/master/bin/screenshot
|
||||
awful.key({ altkey }, "p", function() os.execute("screenshot") end),
|
||||
|
@ -529,43 +529,6 @@ clientkeys = awful.util.table.join(
|
|||
end)
|
||||
)
|
||||
|
||||
-- Bind all key numbers to tags.
|
||||
-- Be careful: we use keycodes to make it works on any keyboard layout.
|
||||
-- This should map on the top row of your keyboard, usually 1 to 9.
|
||||
for i = 1, 9 do
|
||||
globalkeys = awful.util.table.join(globalkeys,
|
||||
awful.key({ modkey }, "#" .. i + 9,
|
||||
function ()
|
||||
local screen = mouse.screen
|
||||
local tag = awful.tag.gettags(screen)[i]
|
||||
if tag then
|
||||
awful.tag.viewonly(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Control" }, "#" .. i + 9,
|
||||
function ()
|
||||
local screen = mouse.screen
|
||||
local tag = awful.tag.gettags(screen)[i]
|
||||
if tag then
|
||||
awful.tag.viewtoggle(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Shift" }, "#" .. i + 9,
|
||||
function ()
|
||||
local tag = awful.tag.gettags(client.focus.screen)[i]
|
||||
if client.focus and tag then
|
||||
awful.client.movetotag(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Control", "Shift" }, "#" .. i + 9,
|
||||
function ()
|
||||
local tag = awful.tag.gettags(client.focus.screen)[i]
|
||||
if client.focus and tag then
|
||||
awful.client.toggletag(tag)
|
||||
end
|
||||
end))
|
||||
end
|
||||
|
||||
clientbuttons = awful.util.table.join(
|
||||
awful.button({ }, 1, function (c) client.focus = c; c:raise() end),
|
||||
awful.button({ modkey }, 1, awful.mouse.client.move),
|
||||
|
|
|
@ -291,7 +291,7 @@ end
|
|||
require("settings.binds")
|
||||
|
||||
-- {{{ Key bindings
|
||||
globalkeys = awful.util.table.join(
|
||||
globalkeys = awful.util.table.join(globalkeys,
|
||||
-- Take a screenshot
|
||||
-- https://github.com/copycat-killer/dots/blob/master/bin/screenshot
|
||||
awful.key({ altkey }, "p", function() os.execute("screenshot") end),
|
||||
|
@ -474,43 +474,6 @@ clientkeys = awful.util.table.join(
|
|||
end)
|
||||
)
|
||||
|
||||
-- Bind all key numbers to tags.
|
||||
-- Be careful: we use keycodes to make it works on any keyboard layout.
|
||||
-- This should map on the top row of your keyboard, usually 1 to 9.
|
||||
for i = 1, 9 do
|
||||
globalkeys = awful.util.table.join(globalkeys,
|
||||
awful.key({ modkey }, "#" .. i + 9,
|
||||
function ()
|
||||
local screen = mouse.screen
|
||||
local tag = awful.tag.gettags(screen)[i]
|
||||
if tag then
|
||||
awful.tag.viewonly(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Control" }, "#" .. i + 9,
|
||||
function ()
|
||||
local screen = mouse.screen
|
||||
local tag = awful.tag.gettags(screen)[i]
|
||||
if tag then
|
||||
awful.tag.viewtoggle(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Shift" }, "#" .. i + 9,
|
||||
function ()
|
||||
local tag = awful.tag.gettags(client.focus.screen)[i]
|
||||
if client.focus and tag then
|
||||
awful.client.movetotag(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Control", "Shift" }, "#" .. i + 9,
|
||||
function ()
|
||||
local tag = awful.tag.gettags(client.focus.screen)[i]
|
||||
if client.focus and tag then
|
||||
awful.client.toggletag(tag)
|
||||
end
|
||||
end))
|
||||
end
|
||||
|
||||
clientbuttons = awful.util.table.join(
|
||||
awful.button({ }, 1, function (c) client.focus = c; c:raise() end),
|
||||
awful.button({ modkey }, 1, awful.mouse.client.move),
|
||||
|
|
|
@ -304,7 +304,7 @@ end
|
|||
require("settings.binds")
|
||||
|
||||
-- {{{ Key bindings
|
||||
globalkeys = awful.util.table.join(
|
||||
globalkeys = awful.util.table.join(globalkeys,
|
||||
-- Take a screenshot
|
||||
-- https://github.com/copycat-killer/dots/blob/master/bin/screenshot
|
||||
awful.key({ altkey }, "p", function() os.execute("screenshot") end),
|
||||
|
@ -483,43 +483,6 @@ clientkeys = awful.util.table.join(
|
|||
end)
|
||||
)
|
||||
|
||||
-- Bind all key numbers to tags.
|
||||
-- Be careful: we use keycodes to make it works on any keyboard layout.
|
||||
-- This should map on the top row of your keyboard, usually 1 to 9.
|
||||
for i = 1, 9 do
|
||||
globalkeys = awful.util.table.join(globalkeys,
|
||||
awful.key({ modkey }, "#" .. i + 9,
|
||||
function ()
|
||||
local screen = mouse.screen
|
||||
local tag = awful.tag.gettags(screen)[i]
|
||||
if tag then
|
||||
awful.tag.viewonly(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Control" }, "#" .. i + 9,
|
||||
function ()
|
||||
local screen = mouse.screen
|
||||
local tag = awful.tag.gettags(screen)[i]
|
||||
if tag then
|
||||
awful.tag.viewtoggle(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Shift" }, "#" .. i + 9,
|
||||
function ()
|
||||
local tag = awful.tag.gettags(client.focus.screen)[i]
|
||||
if client.focus and tag then
|
||||
awful.client.movetotag(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Control", "Shift" }, "#" .. i + 9,
|
||||
function ()
|
||||
local tag = awful.tag.gettags(client.focus.screen)[i]
|
||||
if client.focus and tag then
|
||||
awful.client.toggletag(tag)
|
||||
end
|
||||
end))
|
||||
end
|
||||
|
||||
clientbuttons = awful.util.table.join(
|
||||
awful.button({ }, 1, function (c) client.focus = c; c:raise() end),
|
||||
awful.button({ modkey }, 1, awful.mouse.client.move),
|
||||
|
|
|
@ -7,3 +7,40 @@ root.buttons(awful.util.table.join(
|
|||
awful.button({ }, 5, awful.tag.viewprev)
|
||||
))
|
||||
-- }}}
|
||||
|
||||
-- Bind all key numbers to tags.
|
||||
-- Be careful: we use keycodes to make it works on any keyboard layout.
|
||||
-- This should map on the top row of your keyboard, usually 1 to 9.
|
||||
for i = 1, 9 do
|
||||
globalkeys = awful.util.table.join(globalkeys,
|
||||
awful.key({ modkey }, "#" .. i + 9,
|
||||
function ()
|
||||
local screen = mouse.screen
|
||||
local tag = awful.tag.gettags(screen)[i]
|
||||
if tag then
|
||||
awful.tag.viewonly(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Control" }, "#" .. i + 9,
|
||||
function ()
|
||||
local screen = mouse.screen
|
||||
local tag = awful.tag.gettags(screen)[i]
|
||||
if tag then
|
||||
awful.tag.viewtoggle(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Shift" }, "#" .. i + 9,
|
||||
function ()
|
||||
local tag = awful.tag.gettags(client.focus.screen)[i]
|
||||
if client.focus and tag then
|
||||
awful.client.movetotag(tag)
|
||||
end
|
||||
end),
|
||||
awful.key({ modkey, "Control", "Shift" }, "#" .. i + 9,
|
||||
function ()
|
||||
local tag = awful.tag.gettags(client.focus.screen)[i]
|
||||
if client.focus and tag then
|
||||
awful.client.toggletag(tag)
|
||||
end
|
||||
end))
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue