Skip to content

Commit c0bb62b

Browse files
committed
feat ✨ (zsh): HAD-61 add monitor.lua sub-module with ALT+O/ALT+M binds
1 parent 05eb9ac commit c0bb62b

2 files changed

Lines changed: 33 additions & 0 deletions

File tree

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
-- Keybindings orchestrator
2+
-- Sub-modules are loaded in a specific order to ensure dependencies are met:
3+
-- 1. layout → togglesplit, layout cycle
4+
-- 2. workspace → scratchpad, workspace focus/move, DMS IPC
5+
-- 3. window → HJKL nav, window actions, multimedia keys
6+
-- 4. monitor → window toggle/cycle between monitors, maximize
7+
-- 5. apps → app launcher tiers (direct, hyper, secondary)
8+
9+
local mainMod = "SUPER"
10+
11+
require("configs.binds.layout").register(mainMod)
12+
require("configs.binds.workspace").register(mainMod)
13+
require("configs.binds.window").register(mainMod)
14+
require("configs.binds.monitor").register(mainMod)
15+
require("configs.binds.apps").register(mainMod)
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
-- Monitor management keybindings
2+
-- ALT-based binds for window-to-monitor operations
3+
4+
local M = {}
5+
6+
-- Modifier constants
7+
local ALT = "ALT"
8+
9+
function M.register(mainMod)
10+
-- Toggle window between monitors: ALT + O
11+
-- Cycles forward (1→2→3→1) with 3+ monitors; toggles 1↔2 with 2 monitors
12+
hl.bind(ALT .. " + O", hl.dsp.window.move({ monitor = "+1" }))
13+
14+
-- Maximize window (fill workspace, keep bar visible): ALT + M
15+
hl.bind(ALT .. " + M", hl.dsp.window.fullscreen({ mode = "maximize" }))
16+
end
17+
18+
return M

0 commit comments

Comments
 (0)