adding symlink farm for hyprland launching

This commit is contained in:
2026-07-11 12:40:36 +01:00
parent 1a70f20213
commit e77cb49ffc
2 changed files with 19 additions and 4 deletions

8
flake.lock generated
View File

@@ -373,11 +373,11 @@
"wshowkeys": "wshowkeys" "wshowkeys": "wshowkeys"
}, },
"locked": { "locked": {
"lastModified": 1783762991, "lastModified": 1783770011,
"narHash": "sha256-9qyKPHXc2fK6oZxCXLV9q0WdyNYdgCpfiAouRf+ELrc=", "narHash": "sha256-U+RNUy0UjDgAMIiAVZCJRmtcriGAE4tqOkprvs2/nE4=",
"ref": "refs/heads/main", "ref": "refs/heads/main",
"rev": "9f0f7846c04d8abe0e0a7571d9eadc4749ac910e", "rev": "45818e93959b636b27910689f29cb640da88c8b9",
"revCount": 43, "revCount": 44,
"type": "git", "type": "git",
"url": "https://git.voidarc.co.uk/voidarc/hypr" "url": "https://git.voidarc.co.uk/voidarc/hypr"
}, },

View File

@@ -7,24 +7,39 @@
flake.nixosModules.hyprland = moduleWithSystem ({ flake.nixosModules.hyprland = moduleWithSystem ({
self', self',
pkgs, pkgs,
system,
... ...
}: let }: let
modules = with self.nixosModules; [ modules = with self.nixosModules; [
audio audio
systemTheme systemTheme
]; ];
runtimePkgs = self'.packages.hyprland.passthru.runtimePackages;
lib = pkgs.lib;
in { in {
imports = modules; imports = modules;
programs.hyprland = { programs.hyprland = {
enable = true; enable = true;
package = self'.packages.hyprland; package = self'.packages.hyprland;
portalPackage = inputs.hyprland.inputs.hyprland.packages.${system}.xdg-desktop-portal-hyprland;
}; };
services.xserver.enable = true; services.xserver.enable = true;
security.polkit.enable = true; security.polkit.enable = true;
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
hyprlock hyprlock
gsettings-desktop-schemas gsettings-desktop-schemas
]; ];
system.activationScripts.hyprRuntimeEnv = lib.stringAfter ["specialfs"] ''
mkdir -p /run/hypr-runtime-env/bin
${lib.concatStringsSep "\n" (lib.mapAttrsToList (name: pkg: ''
ln -sfn ${lib.getExe pkg} /run/hypr-runtime-env/bin/${name}
'')
runtimePkgs)}
'';
}); });
perSystem = { perSystem = {
self', self',