nixos/plasma6: add CAP_SYS_NICE for kwin_wayland

This makes kwin_wayland successfully gain SCHED_RR priority, which
significantly improves the rendering lag, ie. cursor movement and
desktop animations, under heavy CPU load like on compilation.
This was already enabled for plasma5 but is not for plasma6 somehow.
This commit is contained in:
oxalica
2024-05-03 02:27:44 -04:00
parent 7db6277090
commit def8d7e254
@@ -286,6 +286,15 @@ in {
kde-smartcard = lib.mkIf config.security.pam.p11.enable { p11Auth = true; };
};
security.wrappers = {
kwin_wayland = {
owner = "root";
group = "root";
capabilities = "cap_sys_nice+ep";
source = "${lib.getBin pkgs.kdePackages.kwin}/bin/kwin_wayland";
};
};
programs.dconf.enable = true;
programs.firefox.nativeMessagingHosts.packages = [kdePackages.plasma-browser-integration];