aboutsummaryrefslogtreecommitdiff
path: root/hypr/configs/keybinds.lua
diff options
context:
space:
mode:
authorBlaster4385 <[email protected]>2026-05-15 23:28:20 +0530
committerBlaster4385 <[email protected]>2026-05-18 16:52:47 +0530
commitf826256c010c0e5c8c2bd64adb1fae1c3f399717 (patch)
tree194e7c15f0903b073d2db3dcae6aa09651341a85 /hypr/configs/keybinds.lua
parent8b254a730b26a40ef2d2ccf0881075a6719b6712 (diff)
feat: migrate hyprland config to luaHEADmain
Diffstat (limited to 'hypr/configs/keybinds.lua')
-rw-r--r--hypr/configs/keybinds.lua113
1 files changed, 113 insertions, 0 deletions
diff --git a/hypr/configs/keybinds.lua b/hypr/configs/keybinds.lua
new file mode 100644
index 0000000..6e5457f
--- /dev/null
+++ b/hypr/configs/keybinds.lua
@@ -0,0 +1,113 @@
+local mainMod = "SUPER"
+
+local terminal = "uwsm app -- kitty"
+local menu = [[uwsm app -- rofi -font "JetBrainsMono Nerd Font 10" -show drun -run-command 'uwsm app -- {cmd}']]
+
+local hy3 = hl.plugin.hy3
+
+hl.bind(mainMod .. " + Return", hl.dsp.exec_cmd(terminal))
+hl.bind(mainMod .. " + Q", hl.dsp.window.close())
+hl.bind(mainMod .. " + M", hl.dsp.exec_cmd("/home/venkatesh/.config/rofi/scripts/rofi-mpris.sh"))
+hl.bind(mainMod .. " + V", hl.dsp.window.float({ action = "toggle" }))
+hl.bind(mainMod .. " + D", hl.dsp.exec_cmd(menu))
+
+hl.bind(
+ mainMod .. " + C",
+ hl.dsp.exec_cmd(
+ [[uwsm app -- rofi -font "JetBrainsMono Nerd Font 10" -modi clipboard:/home/venkatesh/.config/rofi/scripts/cliphist-rofi -show clipboard]]
+ )
+)
+
+hl.bind(mainMod .. " + F", hl.dsp.window.fullscreen())
+hl.bind(mainMod .. " + SHIFT + R", hl.dsp.exec_cmd("hyprctl reload"))
+
+hl.bind(mainMod .. " + W", hy3.change_group("toggletab"))
+
+hl.bind(mainMod .. " + left", hy3.move_focus("l"))
+hl.bind(mainMod .. " + right", hy3.move_focus("r"))
+hl.bind(mainMod .. " + up", hy3.move_focus("u"))
+hl.bind(mainMod .. " + down", hy3.move_focus("d"))
+
+hl.bind(mainMod .. " + SHIFT + left", hy3.move_window("l", { visible = true }))
+hl.bind(mainMod .. " + SHIFT + right", hy3.move_window("r", { visible = true }))
+hl.bind(mainMod .. " + SHIFT + up", hy3.move_window("u", { visible = true }))
+hl.bind(mainMod .. " + SHIFT + down", hy3.move_window("d", { visible = true }))
+
+for i = 1, 10 do
+ local key = i % 10
+
+ hl.bind(
+ mainMod .. " + " .. key,
+ hl.dsp.focus({ workspace = tostring(i) })
+ )
+
+ hl.bind(
+ mainMod .. " + SHIFT + " .. key,
+ hl.dsp.window.move({ workspace = tostring(i) })
+ )
+end
+
+hl.bind(
+ mainMod .. " + SHIFT + SPACE",
+ hl.dsp.window.move({ workspace = "11" })
+)
+
+hl.bind(mainMod .. " + S", hl.dsp.workspace.toggle_special("magic"))
+
+hl.bind(
+ mainMod .. " + SHIFT + S",
+ hl.dsp.window.move({ workspace = "special:magic" })
+)
+
+hl.bind(mainMod .. " + mouse_down",
+ hl.dsp.focus({ workspace = "e+1" }))
+
+hl.bind(mainMod .. " + mouse_up",
+ hl.dsp.focus({ workspace = "e-1" }))
+
+hl.bind(
+ "Print",
+ hl.dsp.exec_cmd([[grim -g "$(slurp -d)" - | wl-copy]])
+)
+
+hl.bind(
+ "XF86AudioRaiseVolume",
+ hl.dsp.exec_cmd("pactl set-sink-volume @DEFAULT_SINK@ +1%")
+)
+
+hl.bind(
+ "XF86AudioLowerVolume",
+ hl.dsp.exec_cmd("pactl set-sink-volume @DEFAULT_SINK@ -1%")
+)
+
+hl.bind(
+ "XF86AudioMute",
+ hl.dsp.exec_cmd("pactl set-sink-mute @DEFAULT_SINK@ toggle")
+)
+
+hl.bind(
+ "XF86AudioMicMute",
+ hl.dsp.exec_cmd("pactl set-source-mute @DEFAULT_SOURCE@ toggle")
+)
+
+hl.bind(
+ mainMod .. " + SUPER_L",
+ hl.dsp.exec_cmd("pkill -SIGUSR1 waybar"),
+ { ignore_mods = true, transparent = true }
+)
+
+hl.bind(
+ mainMod .. " + SUPER_L",
+ hl.dsp.exec_cmd("pkill -SIGUSR1 waybar"),
+ { release = true, transparent = true }
+)
+
+hl.bind(
+ mainMod .. " + B",
+ hl.dsp.exec_cmd("pkill -SIGUSR1 waybar")
+)
+
+hl.bind(
+ mainMod .. " + F1",
+ hl.dsp.exec_cmd("~/.config/hypr/gamemode.sh")
+)