chore(config): adjust workspace bindings and add persistent workspaces for dual monitors

This commit is contained in:
Prad Nukala committed 2026-10-07 13:32:40 -04:00
1 parent cc29237c0c
commit c0f611e1bd
5 files changed
+271 -25

No files matched your search

+5 -7
View File
@@ -143,10 +143,11 @@ o.bind("SUPER + A", "Toggle scratch workspace", "omarchy-toggle-scratch scratchp
o.bind("SUPER + CTRL + ALT + H", "Toggle Tern scratch workspace", "omarchy-toggle-scratch scratchpad")
o.bind("SUPER + CTRL + ALT + L", "Toggle Claude scratch workspace", "omarchy-toggle-scratch claude")
-- Workspaces 1 to 5 on the home row of the left half: ALT to focus,
-- ALT + SHIFT to send the window there. No Omarchy default uses ALT with a
-- letter, so nothing is unbound.
for index, key in ipairs({ "Q", "W", "E", "R", "T" }) do
-- Workspaces 1 to 4 (Studio Display) on Q W E R and 5 to 8 (laptop panel) on
-- Y U I O: ALT to focus, ALT + SHIFT to send the window there. The pinning
-- lives in hypr/hyprland.lua, so focusing a workspace also moves to its
-- monitor. No Omarchy default uses ALT with a letter, so nothing is unbound.
for index, key in ipairs({ "Q", "W", "E", "R", "Y", "U", "I", "O" }) do
local workspace = tostring(index)
o.bind("ALT + " .. key, "Switch to workspace " .. workspace, hl.dsp.focus({ workspace = workspace }))
@@ -156,9 +157,6 @@ end
hl.unbind("SUPER + O") -- was: pop window out
hl.unbind("SUPER + SHIFT + O") -- was: Obsidian (moved to SUPER + CTRL + ALT + O)
o.bind("ALT + O", "Focus next monitor", hl.dsp.focus({ monitor = "+1" }))
o.bind("ALT + SHIFT + O", "Move window to next monitor", hl.dsp.window.move({ monitor = "+1" }))
o.bind("ALT + SHIFT + J", "Move window to next monitor", hl.dsp.window.move({ monitor = "+1" }))
o.bind("ALT + SHIFT + K", "Move window to previous monitor", hl.dsp.window.move({ monitor = "-1" }))
+13 -5
View File
@@ -28,11 +28,19 @@ require("default.hypr.toggles")
-- Add any other personal Hyprland configuration below.
-- o.window("qemu", { workspace = "5" })
-- Pin workspaces to monitors. Matched on EDID description for the external
-- display so it survives landing on a different DP connector after re-docking.
hl.workspace_rule({ workspace = "3", monitor = "desc:Apple Computer Inc StudioDisplay 0x984262A7" })
hl.workspace_rule({ workspace = "4", monitor = "eDP-1" })
hl.workspace_rule({ workspace = "5", monitor = "eDP-1" })
-- Pin workspaces to monitors: 1-4 on the Studio Display, 5-8 on the laptop
-- panel; 1 and 5 are what each shows on connect. Persistent so empty ones
-- stay on their monitor (the bar's workspace dots list them per monitor).
-- Matched on EDID description for the external display so it survives
-- landing on a different DP connector after re-docking.
for id = 1, 8 do
hl.workspace_rule({
workspace = tostring(id),
monitor = id <= 4 and "desc:Apple Computer Inc StudioDisplay 0x984262A7" or "eDP-1",
default = id == 1 or id == 5,
persistent = true,
})
end
-- Always open these apps on a fixed workspace and follow them there. Classes
-- come from `hyprctl clients` -- the desktop files' StartupWMClass hints