# {{{autogen}}} { lib, config, pkgs, flakeRoot, ... }: let username = config.defaultUser or "henrov"; basePath = "${flakeRoot}/generated/.config"; assetPath = "${flakeRoot}/generated/.config/hypr"; in { ################################# # Install hyprlock system-wide ################################# environment.systemPackages = [ pkgs.hyprlock ]; ################################# # Deploy configuration file ################################# home-manager.users = { ${username} = { home.file = { ".config/hypr/hyprlock.conf" = { text = builtins.readFile "${assetPath}/hyprlock.conf"; force = true; }; }; }; }; ################################# # Optional: helper systemd user service (manual start use) ################################# systemd.user.services.hyprlock = { description = "Hyprlock (manual lock session)"; after = [ "graphical-session.target" ]; serviceConfig = { ExecStart = "${pkgs.hyprlock}/bin/hyprlock"; Restart = "no"; Environment = '' WAYLAND_DISPLAY=${config.environment.sessionVariables.WAYLAND_DISPLAY or "wayland-0"} XDG_CURRENT_DESKTOP=Hyprland ''; }; wantedBy = [ ]; }; }