60 lines
3.4 KiB
Lua
60 lines
3.4 KiB
Lua
-- Open rofi on first press, closes it on second
|
|
hl.bind("SUPER + Space", hl.dsp.exec_raw("rofi -show combi --modes combi"),
|
|
{ release = true, description = "Open Application Menu" })
|
|
hl.bind("SUPER + SHIFT + SPACE", hl.dsp.exec_cmd("~/.local/bin/hyprland-fetch-client"),
|
|
{ release = true, description = "Fetch client" })
|
|
hl.bind("SUPER + CONTROL + SPACE",
|
|
hl.dsp.exec_cmd("~/.local/bin/hyprland-focus-client"),
|
|
{ release = true, description = "Focus client" }
|
|
)
|
|
hl.bind("SUPER + slash",
|
|
hl.dsp.exec_cmd("ROFI_PASS_BACKEND=wtype ROFI_PASS_CLIPBOARD_BACKEND=wl-clipboard ~/.local/bin/rofi-pass"),
|
|
{ release = true, description = "Open rofi-pass" })
|
|
|
|
hl.bind("SUPER + Y", hl.dsp.exec_cmd("makoctl dismiss"), { description = "Dismiss notifications" })
|
|
|
|
hl.bind(sjb.HYPR .. "V", hl.dsp.exec_cmd("pavucontrol"), { description = "Volume control" })
|
|
hl.bind(sjb.HYPR .. "B", hl.dsp.exec_cmd("blueberry"), { description = "Bluetooth manager" })
|
|
|
|
hl.bind("SUPER + Escape", hl.dsp.exec_raw("loginctl lock-session"), { description = "Lock screen" })
|
|
hl.bind("SUPER + SHIFT + escape", hl.dsp.exec_raw("systemctl suspend"), { description = "Suspend" })
|
|
hl.bind("SUPER + ALT + escape", hl.dsp.exit(), { description = "Exit Hyprland" })
|
|
hl.bind("SUPER + CONTROL + escape", hl.dsp.exec_raw("reboot"), { description = "Reboot" })
|
|
hl.bind("SUPER + SHIFT + CONTROL + escape", hl.dsp.exec_raw("systemctl poweroff"), { description = "Power off" })
|
|
|
|
hl.bind("Print",
|
|
hl.dsp.exec_cmd("hyprshot -m window -o ~/Pictures/ -- tensaku-edit"),
|
|
{ description = "Take screenshot" })
|
|
|
|
hl.bind("SHIFT + PRINT",
|
|
hl.dsp.exec_cmd("hyprshot -m region -o ~/Pictures/ -- tensaku-edit"),
|
|
{ description = "Take screenshot" })
|
|
|
|
hl.bind("SUPER + PRINT", hl.dsp.exec_cmd("pkill hyprpicker || hyprpicker -a"), { description = "Pick color" })
|
|
hl.bind("SUPER + CONTROL + PRINT",
|
|
hl.dsp.exec_cmd("hyprshot -m region --raw -z | /usr/bin/tesseract stdin stdout --oem 1 --psm 6 -l eng | wl-copy"),
|
|
{ description = "Extract text (OCR) from screenshot" })
|
|
|
|
hl.bind("SUPER + ALT + Print",
|
|
hl.dsp.exec_cmd("~/.local/bin/screen-recorder -o ~/Videos/$(date +'%Y-%m-%d_%H%M%S')_recording.mp4"),
|
|
{ description = "Start/Stop screen recording" })
|
|
|
|
hl.bind("SUPER + ALT + SHIFT + Print",
|
|
hl.dsp.exec_cmd("~/.local/bin/screen-recorder stop"),
|
|
{ description = "Stop screen recording" })
|
|
|
|
hl.bind("XF86AudioLowerVolume", hl.dsp.exec_cmd("wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%-"),
|
|
{ repeating = true, description = "Volume down" })
|
|
hl.bind("XF86AudioRaiseVolume", hl.dsp.exec_cmd("wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%+"),
|
|
{ repeating = true, description = "Volume up" })
|
|
hl.bind("XF86AudioMute", hl.dsp.exec_cmd("wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle"), { description = "Toggle mute" })
|
|
hl.bind("XF86AudioMicMute", hl.dsp.exec_cmd("wpctl set-mute @DEFAULT_AUDIO_SOURCE@ toggle"),
|
|
{ description = "Toggle mic mute" })
|
|
hl.bind("XF86MonBrightnessUp", hl.dsp.exec_cmd("brightnessctl s 10%+"),
|
|
{ repeating = true, description = "Brightness up" })
|
|
hl.bind("XF86MonBrightnessDown", hl.dsp.exec_cmd("brightnessctl s 10%-"),
|
|
{ repeating = true, description = "Brightness down" })
|
|
hl.bind("XF86AudioPlay", hl.dsp.exec_cmd("playerctl play-pause"), { description = "Play/pause media" })
|
|
hl.bind("XF86AudioPrev", hl.dsp.exec_cmd("playerctl previous"), { description = "Previous media" })
|
|
hl.bind("XF86AudioNext", hl.dsp.exec_cmd("playerctl next"), { description = "Next media" })
|