From e7d60e71c39458cf763d47404a5c5bb961fe244b Mon Sep 17 00:00:00 2001 From: joygnu Date: Tue, 16 Jul 2024 11:38:55 +0200 Subject: [PATCH] polkit --- home/hyprland/default.nix | 4 ---- modules/default.nix | 1 + modules/polkit/default.nix | 19 +++++++++++++++++++ 3 files changed, 20 insertions(+), 4 deletions(-) create mode 100644 modules/polkit/default.nix diff --git a/home/hyprland/default.nix b/home/hyprland/default.nix index 6774748..0a3d230 100644 --- a/home/hyprland/default.nix +++ b/home/hyprland/default.nix @@ -28,9 +28,6 @@ "DP-1,2560x1440@165.00Hz,0x0,1,bitdepth,10" ]; - windowrule = [ - "float, lxqt-policykit-agent" - ]; env = [ "HYPRCURSOR_THEME = Bibata-Modern-Ice" @@ -38,7 +35,6 @@ ]; exec-once = [ - "lxqt-policykit-agent &" "ags -c ~/nix/home/ags/bar/config.js &" "wl-paste --type text --watch cliphist store" "wl-paste --type image --watch cliphist store" diff --git a/modules/default.nix b/modules/default.nix index a96de0f..3d8f6fc 100644 --- a/modules/default.nix +++ b/modules/default.nix @@ -13,5 +13,6 @@ ./gpg ./appimage ./update + ./polkit ]; } diff --git a/modules/polkit/default.nix b/modules/polkit/default.nix new file mode 100644 index 0000000..84282ce --- /dev/null +++ b/modules/polkit/default.nix @@ -0,0 +1,19 @@ +{ pkgs, ... } : +{ + systemd = { + user.services.polkit-gnome-authentication-agent-1 = { + description = "polkit-gnome-authentication-agent-1"; + wantedBy = [ "graphical-session.target" ]; + wants = [ "graphical-session.target" ]; + after = [ "graphical-session.target" ]; + serviceConfig = { + Type = "simple"; + ExecStart = "${pkgs.polkit_gnome}/libexec/polkit-gnome-authentication-agent-1"; + Restart = "on-failure"; + RestartSec = 1; + TimeoutStopSec = 10; + }; + }; + }; +} +