nix-conf/home/user/hyprland.nix
2024-12-29 14:14:12 +08:00

38 lines
1,019 B
Nix

{ pkgs, lib, inputs, ... }:
{
# Have not figured out how to config throught homeManager yet
wayland.windowManager.hyprland = {
enable = true;
package = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.hyprland;
xwayland.enable = true;
systemd.enable = true;
plugins = [
inputs.hyprland-plugins.packages.${pkgs.stdenv.hostPlatform.system}.hyprbars
inputs.hyprgrass.packages.${pkgs.system}.default
];
settings = {
"$mod" = "SUPER";
bind = [
"$mod, F, exec, firefox"
"$mod, enter, exec, ghostty"
]
++ (
# workspaces
# binds $mod + [shift +] {1..9} to [move to] workspace {1..9}
builtins.concatLists (builtins.genList
(i:
let ws = i + 1;
in
[
"$mod, code:1${toString i}, workspace, ${toString ws}"
"$mod SHIFT, code:1${toString i}, movetoworkspace, ${toString ws}"
]
)
9)
);
};
};
}