dotfiles/.config/hypr/configs/binds.conf

197 lines
7 KiB
Text

# Variables
$scripts = ~/.config/hypr/scripts
$custom_app_launch = $scripts/custom_app_launch
$hyprshot = $scripts/hyprshot -o ~/Imagenes/Capturas/PC -f captura-$(date +%Y-%m-%d-%s).png
$workspace = $scripts/awesome_workspaces
# Mouse binds
bindm = SUPER, mouse:272, movewindow
bindm = SUPER, mouse:273, resizewindow
# Basic keybinds
bind = SUPER, Q, killactive,
bind = SUPERCTRL, R, exec, pkill waybar || waybar
bind = SUPERCTRL, M, exit
bind = SUPER, A, exec, $scripts/toggle_floating
bind = SUPER, P, pseudo
bind = SUPER, F, fullscreen, 0
bind = SUPER, Z, exec, pypr zoom
# Applications
bind = SUPER, W, exec, $custom_app_launch browser
bind = SUPER, O, exec, $custom_app_launch obsidian
bind = SUPERSHIFT, O, exec, $custom_app_launch office
bind = SUPERSHIFT, E,exec, $custom_app_launch nemo
bind = SUPER, RETURN, exec, kitty
bind = SUPERSHIFT, RETURN, exec, kitty --class=center-float-large
bind = SUPERALT, RETURN, exec, kitty --class=center-float
bind = SUPERCTRL, RETURN, exec, kitty --class=center-float-mini
bind = SUPER, BACKSPACE, exec, $custom_app_launch nvim
bind = SUPERSHIFT, BACKSPACE, exec, $custom_app_launch codium
# Pickers/Launchers
bind = SUPER, 23, exec, rofi -show drun # Tab
bind = SUPER, INSERT, exec, $scripts/color_picker
bind = SUPERSHIFT, W, exec, $scripts/wallpaper select
bind = SUPERCTRL, W, exec, pypr wall next
bind = SUPER, 61, exec, $scripts/rofi/keybindings # /
bind = SUPERSHIFT, G, exec, $scripts/rofi/game_launcher
bind = SUPER, Y, exec, cliphist list | rofi -dmenu | cliphist decode | wl-copy
# Scratchpads
bind = SUPER, V, exec, pypr toggle volume
bind = SUPER, 51, exec, pypr toggle terminal # Backslash
bind = SUPER, B, exec, pypr toggle btop
bind = SUPERSHIFT, I, exec, pypr toggle gpt
bind = SUPERSHIFT, B, exec, pypr toggle bluetooth
bind = SUPER, E, exec, pypr toggle yazi
bind = SUPER, D, exec, pypr toggle dots
bind = SUPERSHIFT, C, exec, pypr toggle cava
bind = SUPER, U, exec, pypr toggle topgrade-system
bind = SUPERSHIFT, U, exec, pypr toggle topgrade-all
# Screenshot stuff
bind = SHIFT, INSERT, exec, $hyprshot -m output
bind = SUPERSHIFT, INSERT, exec, $hyprshot -m window
bind = CTRL, INSERT, exec, $hyprshot -m region
bind = ALT, INSERT, exec, $scripts/rofi/screenshots_selection
# Notifications menu
bind = SUPER, N, exec, swaync-client -t
# Logout menu
bind = SUPER, ESCAPE, exec, wleave
# Windows
# Focusing on windows
bind = SUPER, LEFT, movefocus, l
bind = SUPER, RIGHT, movefocus, r
bind = SUPER, UP, movefocus, u
bind = SUPER, DOWN, movefocus, d
# Vim-keybinds
bind = SUPER, H, movefocus, l
bind = SUPER, L, movefocus, r
bind = SUPER, K, movefocus, u
bind = SUPER, J, movefocus, d
# Moving windows
bind = SUPERSHIFT, LEFT, movewindow, l
bind = SUPERSHIFT, RIGHT, movewindow, r
bind = SUPERSHIFT, UP, movewindow, u
bind = SUPERSHIFT, DOWN, movewindow, d
# Vim-keybinds
bind = SUPERSHIFT, H, movewindow, l
bind = SUPERSHIFT, L, movewindow, r
bind = SUPERSHIFT, K, movewindow, u
bind = SUPERSHIFT, J, movewindow, d
bind = SUPERSHIFT, 51, exec, $scripts/move_by_rules # Backslash
# Center and split
bind = SUPER, S, togglesplit
bind = SUPER, C, exec, hyprctl dispatch centerwindow 1
# Workspaces
# Focusing other workspaces
bind = SUPER, 1, exec, $workspace 1 switch
bind = SUPER, 2, exec, $workspace 2 switch
bind = SUPER, 3, exec, $workspace 3 switch
bind = SUPER, 4, exec, $workspace 4 switch
bind = SUPER, 5, exec, $workspace 5 switch
bind = SUPER, 6, exec, $workspace 6 switch
bind = SUPER, 7, exec, $workspace 7 switch
bind = SUPER, 8, exec, $workspace 8 switch
bind = SUPER, 9, exec, $workspace 9 switch
# Moving windows to other workspaces
bind = SUPERSHIFT, 1, exec, $workspace 1 move
bind = SUPERSHIFT, 2, exec, $workspace 2 move
bind = SUPERSHIFT, 3, exec, $workspace 3 move
bind = SUPERSHIFT, 4, exec, $workspace 4 move
bind = SUPERSHIFT, 5, exec, $workspace 5 move
bind = SUPERSHIFT, 6, exec, $workspace 6 move
bind = SUPERSHIFT, 7, exec, $workspace 7 move
bind = SUPERSHIFT, 8, exec, $workspace 8 move
bind = SUPERSHIFT, 9, exec, $workspace 9 move
# Moving windows to other workspaces (silent)
bind = SUPERALT, 1, exec, $workspace 1 silent
bind = SUPERALT, 2, exec, $workspace 2 silent
bind = SUPERALT, 3, exec, $workspace 3 silent
bind = SUPERALT, 4, exec, $workspace 4 silent
bind = SUPERALT, 5, exec, $workspace 5 silent
bind = SUPERALT, 6, exec, $workspace 6 silent
bind = SUPERALT, 7, exec, $workspace 7 silent
bind = SUPERALT, 8, exec, $workspace 8 silent
bind = SUPERALT, 9, exec, $workspace 9 silent
# Moving to other workspace with mouse control
bind = SUPER, mouse_down, workspace, m-1
bind = SUPER, mouse_up, workspace, m+1
# Moving to other workspace with keyboard
bind = SUPERCTRL, LEFT, workspace, m-1
bind = SUPERCTRL, RIGHT, workspace, m+1
bind = SUPERCTRL, H, workspace, m-1
bind = SUPERCTRL, L, workspace, m+1
# Moving to next and prev monitors
bind = SUPER, 59, focusmonitor, -1 # Comma
bind = SUPER, 60, focusmonitor, +1 # Period
# Group control
bind = SUPER, G, togglegroup
bind = ALT, ESCAPE, changegroupactive
# Submap for resizing windows
bind = SUPER, R, submap, resize
submap = resize
binde = , RIGHT, resizeactive, 40 0
binde = , LEFT, resizeactive, -40 0
binde = , UP, resizeactive, 0 -40
binde = , DOWN, resizeactive, 0 40
binde = , L, resizeactive, 40 0
binde = , H, resizeactive, -40 0
binde = , K, resizeactive, 0 -40
binde = , J, resizeactive, 0 40
bind = , ESCAPE, submap, reset
submap = reset
# Audio
bind = SUPERCTRL, V, exec, ~/.local/bin/restartAudio
bindl = SUPERCTRL, mouse:280, exec, swayosd-client --output-volume mute-toggle # Extra Up Button
bindl = , XF86AudioMute, exec, swayosd-client --output-volume mute-toggle
bindl = SUPERCTRL, mouse:281, exec, swayosd-client --input-volume mute-toggle # Extra Down Button
bindl = , XF86AudioMicMute, exec, exec swayosd-client --input-volume mute-toggle
bindl = , XF86AudioPlay, exec, playerctl play-pause
bindl = SUPERCTRL, mouse:282, exec, playerctl play-pause # Extra Center Button
bindl = , XF86AudioPrev, exec, playerctl previous
bindl = SUPERCTRL, mouse:275, exec, playerctl previous # Extra Back Button
bindl = , XF86AudioNext, exec, playerctl next
bindl = SUPERCTRL, mouse:276, exec, playerctl next # Extra Forward Button
bindle = , XF86AudioRaiseVolume, exec, swayosd-client --output-volume raise
bindle = SUPERCTRL, 21, exec, swayosd-client --output-volume raise # Minus key
bindle = , XF86AudioLowerVolume, exec, swayosd-client --output-volume lower
bindle = SUPERCTRL, 20, exec, swayosd-client --output-volume lower # Plus key
bindle = , XF86InputRaiseVolume, exec, swayosd-client --input-volume raise
bindle = SUPERSHIFT, 21, exec, swayosd-client --input-volume raise # Minus key
bindle = , XF86InputLowerVolume, exec, swayosd-client --input-volume lower
bindle = SUPERSHIFT, 20, exec, swayosd-client --input-volume lower # Plus key
# Disable anim, blur, etc
bind = SUPER, F12, exec, $scripts/performance
# Open Wiki
bind = SUPER, F1, exec, xdg-open https://wiki.hyprland.org/
bind = SUPERSHIFT, F1, exec, xdg-open https://github.com/Matt-FTW/dotfiles/wiki
# Freeze active window
bind = SUPERSHIFT, ESCAPE, exec, $scripts/hyprfreeze -a