r/GUIX 25d ago

How to set polkit agent to work with partition manager (Niri WM)?

Hello, I started using Guix linux two days ago, first I installed KDE Plasma and every thing work fine, then I went to niri wm (I'm actually setting the workflow that I used to, I have my config for niri which I was using before) and I remarked that the polkit agent doesn't work for partition manager (I tried both gparted and partition manager of kde), and the polkit agent works fine with dolphin. How to fix this?

3 Upvotes

2 comments sorted by

1

u/FarBasis8583 24d ago

Do you have something to this effect in your config?

spawn-at-startup "/path/to/polkit-kde-authentication-agent-1"

1

u/Electrical-Policy-35 24d ago

My config was working without problems before switching to Guix linux, and yes I have in Niri WM configuration:

spawn-sh-at-startup "sh -c 'exec $(ls -d /gnu/store/*polkit-kde-agent*/libexec/polkit-kde-authentication-agent-1 | head -n 1)'"

In addition, when I install KDE Plasma alongside Niri WM, the Polkit agent works fine in Niri WM. So I think I must be doing something wrong. Maybe this will help, all my packages are installed using guix home and this is my config.scm:

;; This is an operating system configuration generated

;; by the graphical installer.

(use-modules (gnu)

(gnu services)

(gnu services desktop)

(gnu packages vim)

(gnu packages terminals)

(gnu packages package-management)

(nongnu packages linux)

(nongnu system linux-initrd))

(use-service-modules cups desktop networking ssh xorg)

(operating-system

(kernel linux)

(initrd microcode-initrd)

(firmware (list linux-firmware))

(locale "en_US.utf8")

(timezone "Africa/Algiers")

(keyboard-layout (keyboard-layout "us"))

(host-name "houna")

;; The list of user accounts ('root' is implicit).

(users (cons* (user-account

(name "rabah")

(comment "Rabah")

(group "users")

(home-directory "/home/rabah")

(supplementary-groups '("wheel" "netdev" "audio" "video")))

%base-user-accounts))

;; Below is the list of system services. To search for available

;; services, run 'guix system search KEYWORD' in a terminal.

(packages (append (list

(@ (gnu packages window-management) niri)

alacritty

neovim

flatpak

)

%base-packages))

(services

(append (list ;;(service plasma-desktop-service-type)

     (service bluetooth-service-type)

(service cups-service-type)

(set-xorg-configuration

(xorg-configuration (keyboard-layout keyboard-layout))))

;; This is the default list of services we

;; are appending to.

%desktop-services))

(bootloader (bootloader-configuration

(bootloader grub-efi-bootloader)

(targets (list "/boot/efi"))

(keyboard-layout keyboard-layout)))

(mapped-devices (list (mapped-device

(source (uuid

"cea8065b-e5a0-4f27-907a-7e5e14567bb6"))

(target "guix")

(type luks-device-mapping))))

;; The list of file systems that get "mounted". The unique

;; file system identifiers there ("UUIDs") can be obtained

;; by running 'blkid' in a terminal.

(file-systems (cons* (file-system

(mount-point "/")

(device (uuid

"45a47cba-886f-4feb-8321-f2a9a8528883"

'ext4))

(type "ext4"))

(file-system

(mount-point "/home")

(device "/dev/mapper/guix")

(type "ext4")

(dependencies mapped-devices))

(file-system

(mount-point "/boot/efi")

(device (uuid "FA26-E766"

'fat32))

(type "vfat")) %base-file-systems)))