Files
dotfiles/config/modules/hyprland/hyprland.nix
T
2026-06-07 18:45:11 +01:00

59 lines
1.6 KiB
Nix

{
modules,
inputs,
lib,
...
}: {
flake-file.inputs = {
hyprland.url = "github:hyprwm/Hyprland";
};
modules.hyprland = {
nixos = {pkgs, ...}: {
imports = [inputs.hyprland.nixosModules.default];
environment.systemPackages = with pkgs; [
wayfreeze
grim
slurp
wlogout
ranger
];
programs.xwayland.enable = true;
programs.hyprland = {
enable = true;
# withUWSM = true;
# set the flake package
package = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.hyprland;
# make sure to also set the portal package, so that they are in sync
portalPackage =
inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.xdg-desktop-portal-hyprland;
};
# gtk.enable = lib.mkForce false;
xdg.portal = {
enable = true;
extraPortals = [
inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.xdg-desktop-portal-hyprland
];
};
environment.sessionVariables.NIXOS_OZONE_WL = "1";
hardware.graphics = {
# package = pkgs-unstable.mesa;
# if you also want 32-bit support (e.g for Steam)
# enable32Bit = true;
# package32 = pkgs-unstable.pkgsi686Linux.mesa;
};
};
homeManager = {pkgs, ...}: {
gtk = {
enable = true;
};
# backupFileExtension = "backupHM";
wayland.windowManager.hyprland = {
enable = true;
systemd.variables = ["--all"];
configType = "hyprlang";
};
};
};
}