feat(nixos): add Hyprland to home-manager

This commit is contained in:
Mohammad Rafiq 2025-02-22 16:09:55 +08:00
parent a7986e8f8f
commit 8b43e47c2a
2 changed files with 58 additions and 1 deletions

31
flake.lock generated
View file

@ -178,6 +178,36 @@
"type": "github"
}
},
"hyprland-plugins": {
"inputs": {
"hyprland": [
"hyprland"
],
"nixpkgs": [
"hyprland-plugins",
"hyprland",
"nixpkgs"
],
"systems": [
"hyprland-plugins",
"hyprland",
"systems"
]
},
"locked": {
"lastModified": 1738966025,
"narHash": "sha256-MzgrF0jKlTNnNS33D8PwI5z2MJ1Tzf5MQVf/oms2pdw=",
"owner": "hyprwm",
"repo": "hyprland-plugins",
"rev": "4f48dbe12f3cbbeb4d31c91c67b21edbc5b4b451",
"type": "github"
},
"original": {
"owner": "hyprwm",
"repo": "hyprland-plugins",
"type": "github"
}
},
"hyprland-protocols": {
"inputs": {
"nixpkgs": [
@ -409,6 +439,7 @@
"inputs": {
"home-manager": "home-manager",
"hyprland": "hyprland",
"hyprland-plugins": "hyprland-plugins",
"nixpkgs": "nixpkgs_2"
}
},

View file

@ -1,4 +1,4 @@
{ config, pkgs, ... }:
{ config, pkgs, inputs, ... }:
{
home.username = "rafiq";
@ -35,6 +35,32 @@
};
};
wayland.windowManager.hyprland = {
enable = true;
# Set these to null to use the packages defined in the system config.
package = null;
portalPackage = null;
plugins = with pkgs.hyprlandPlugins; [
# borders-plus-plus
# inputs.hyprland-plugins.packages.${pkgs.stdenv.hostPlatform.system}.<plugin>
# hypr-dynamic-cursors # requires notifications set up
];
settings = {
"$mainMod" = "SUPER"; # Sets the modifier key to Windows key
"$terminal" = "kitty";
bind = [
"$mainMod, Q, exec, $terminal"
"$mainMod, W, killactive"
];
debug = {
disable_logs = false;
};
};
};
home.stateVersion = "24.11";
programs.home-manager.enable = true;
}