This commit is contained in:
commit
95a533c876
451 changed files with 18255 additions and 0 deletions
34
modules/home/hyprland/binds/default.nix
Normal file
34
modules/home/hyprland/binds/default.nix
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
cfg = config.wayland.windowManager.hyprland;
|
||||
|
||||
hyprland = import ./hyprland.nix;
|
||||
mediakeys = import ./mediakeys.nix { inherit pkgs; };
|
||||
windows = import ./windows.nix;
|
||||
workspaces = import ./workspaces.nix;
|
||||
|
||||
binds = builtins.concatLists [
|
||||
hyprland
|
||||
mediakeys
|
||||
windows
|
||||
workspaces
|
||||
];
|
||||
|
||||
inherit (lib) mkIf;
|
||||
in
|
||||
{
|
||||
config = mkIf cfg.enable {
|
||||
wayland.windowManager.hyprland = {
|
||||
settings = {
|
||||
bind = binds;
|
||||
bindm = (import ./mouse.nix);
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
3
modules/home/hyprland/binds/hyprland.nix
Normal file
3
modules/home/hyprland/binds/hyprland.nix
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
[
|
||||
# "$mod CTRL, b, exec, killall -SIGUSR1 waybar" # toggle bar # FIXME: waybar: no process found
|
||||
]
|
||||
22
modules/home/hyprland/binds/mediakeys.nix
Normal file
22
modules/home/hyprland/binds/mediakeys.nix
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
{ pkgs, ... }:
|
||||
|
||||
let
|
||||
brightness = "${pkgs.brightnessctl}/bin/brightnessctl";
|
||||
player = "${pkgs.playerctl}/bin/playerctl";
|
||||
volume = "${pkgs.pulseaudio}/bin/pactl";
|
||||
in
|
||||
[
|
||||
", XF86MonBrightnessUp, exec, ${brightness} s +5%" # increase screen brightness
|
||||
", XF86MonBrightnessDown, exec, ${brightness} s 5%-" # decrease screen brightness
|
||||
", XF86AudioRaiseVolume, exec, ${volume} set-sink-volume 0 +5%" # raise speaker volume
|
||||
", XF86AudioLowerVolume, exec, ${volume} set-sink-volume 0 -5%" # lower speaker volume
|
||||
"SHIFT, XF86AudioRaiseVolume, exec, ${volume} set-source-volume 0 +1%" # raise mic volume
|
||||
"SHIFT, XF86AudioLowerVolume, exec, ${volume} set-source-volume 0 -1%" # lower mic volume
|
||||
", XF86AudioMute, exec, ${volume} set-sink-mute 0 toggle" # mute/unmute speaker
|
||||
"SHIFT, XF86AudioMute, exec, ${volume} set-source-mute 0 toggle" # mute/unmute mic
|
||||
", XF86AudioMicMute, exec, ${volume} set-source-mute 0 toggle" # mute/unmute mic
|
||||
", XF86AudioPlay, exec, ${player} play-pause" # toggle between play and pause music
|
||||
", XF86AudioStop, exec, ${player} stop" # stop music
|
||||
", XF86AudioPrev, exec, ${player} previous" # play previous
|
||||
", XF86AudioNext, exec, ${player} next" # play next
|
||||
]
|
||||
4
modules/home/hyprland/binds/mouse.nix
Normal file
4
modules/home/hyprland/binds/mouse.nix
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
[
|
||||
"$mod, mouse:272, movewindow" # left mouse button
|
||||
"$mod, mouse:273, resizewindow" # right mouse button
|
||||
]
|
||||
27
modules/home/hyprland/binds/windows.nix
Normal file
27
modules/home/hyprland/binds/windows.nix
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
[
|
||||
"$mod SHIFT, c, killactive" # kill active window
|
||||
"$mod SHIFT, Return, layoutmsg, swapwithmaster master" # make active window master
|
||||
"$mod CTRL, Return, layoutmsg, focusmaster" # focus master
|
||||
"$mod, j, layoutmsg, cyclenext" # focus next window
|
||||
"$mod, k, layoutmsg, cycleprev" # focus previous window
|
||||
"$mod SHIFT, j, layoutmsg, swapnext" # swaps window with next
|
||||
"$mod SHIFT, k, layoutmsg, swapprev" # swaps window with previous
|
||||
"$mod, h, splitratio, -0.05" # decrease horizontal space of master stack
|
||||
"$mod, l, splitratio, +0.05" # increase horizontal space of master stack
|
||||
"$mod SHIFT, h, resizeactive, 0 -40" # shrink active window vertically
|
||||
"$mod SHIFT, l, resizeactive, 0 40" # expand active window vertically
|
||||
"$mod, i, layoutmsg, addmaster" # add active window to master stack
|
||||
"$mod SHIFT, i, layoutmsg, removemaster" # remove active window from master stack
|
||||
"$mod, o, layoutmsg, orientationcycle left top" # toggle between left and top orientation
|
||||
"$mod, left, movefocus, l" # focus window to the left
|
||||
"$mod, right, movefocus, r" # focus window to the right
|
||||
"$mod, up, movefocus, u" # focus upper window
|
||||
"$mod, down, movefocus, d" # focus lower window
|
||||
"$mod SHIFT, left, swapwindow, l" # swap active window with window to the left
|
||||
"$mod SHIFT, right, swapwindow, r" # swap active window with window to the right
|
||||
"$mod SHIFT, up, swapwindow, u" # swap active window with upper window
|
||||
"$mod SHIFT, down, swapwindow, d" # swap active window with lower window
|
||||
"$mod, f, togglefloating" # toggle floating for active window
|
||||
"$mod CTRL, f, workspaceopt, allfloat" # toggle floating for all windows on workspace
|
||||
"$mod SHIFT, f, fullscreen" # toggle fullscreen for active window
|
||||
]
|
||||
38
modules/home/hyprland/binds/workspaces.nix
Normal file
38
modules/home/hyprland/binds/workspaces.nix
Normal file
|
|
@ -0,0 +1,38 @@
|
|||
[
|
||||
"$mod, 1, workspace, 1" # go to workspace 1
|
||||
"$mod, 2, workspace, 2" # ...
|
||||
"$mod, 3, workspace, 3"
|
||||
"$mod, 4, workspace, 4"
|
||||
"$mod, 5, workspace, 5"
|
||||
"$mod, 6, workspace, 6"
|
||||
"$mod, 7, workspace, 7"
|
||||
"$mod, 8, workspace, 8"
|
||||
"$mod, 9, workspace, 9"
|
||||
"$mod, 0, workspace, 10"
|
||||
"$mod SHIFT, 1, movetoworkspacesilent, 1" # move active window to workspace 1
|
||||
"$mod SHIFT, 2, movetoworkspacesilent, 2" # ...
|
||||
"$mod SHIFT, 3, movetoworkspacesilent, 3"
|
||||
"$mod SHIFT, 4, movetoworkspacesilent, 4"
|
||||
"$mod SHIFT, 5, movetoworkspacesilent, 5"
|
||||
"$mod SHIFT, 6, movetoworkspacesilent, 6"
|
||||
"$mod SHIFT, 7, movetoworkspacesilent, 7"
|
||||
"$mod SHIFT, 8, movetoworkspacesilent, 8"
|
||||
"$mod SHIFT, 9, movetoworkspacesilent, 9"
|
||||
"$mod SHIFT, 0, movetoworkspacesilent, 10"
|
||||
"$mod CTRL, 1, focusworkspaceoncurrentmonitor, 1" # focus workspace 1 on current monitor
|
||||
"$mod CTRL, 2, focusworkspaceoncurrentmonitor, 2" # ...
|
||||
"$mod CTRL, 3, focusworkspaceoncurrentmonitor, 3"
|
||||
"$mod CTRL, 4, focusworkspaceoncurrentmonitor, 4"
|
||||
"$mod CTRL, 5, focusworkspaceoncurrentmonitor, 5"
|
||||
"$mod CTRL, 6, focusworkspaceoncurrentmonitor, 6"
|
||||
"$mod CTRL, 7, focusworkspaceoncurrentmonitor, 7"
|
||||
"$mod CTRL, 8, focusworkspaceoncurrentmonitor, 8"
|
||||
"$mod CTRL, 9, focusworkspaceoncurrentmonitor, 9"
|
||||
"$mod CTRL, 0, focusworkspaceoncurrentmonitor, 10"
|
||||
"$mod, Tab, workspace, previous_per_monitor" # go to previous workspace
|
||||
"$mod SHIFT, Tab, movetoworkspace, previous_per_monitor" # move active window to previous workspace
|
||||
"$mod, comma, focusmonitor, l" # go to left monitor
|
||||
"$mod, period, focusmonitor, r" # go to right monitor
|
||||
"$mod SHIFT, comma, movecurrentworkspacetomonitor, l" # move current workspace to left monitor
|
||||
"$mod SHIFT, period, movecurrentworkspacetomonitor, r" # move current workspace to right monitor
|
||||
]
|
||||
Loading…
Add table
Add a link
Reference in a new issue