Hi, I'd like to make an expression for KScreen<http://www.afiestas.org/kscreen-1-0-released/>(screens management done right). Here is the issue: to enable it you have to do three steps:
1. Unload randrmonitor (that's the module we are going to replace). 2. Set randrmonitor not to autoload. 3. Load kscreen. 1 and 3 are dbus calls. 2 can be done with a dbus call, but this call will just write an option to ~/.kde/share/config/kdedrc. A little bit on how kded module loading works. Every kded module installs a .desktop file to /usr/share/kde4/services/kded (/nix/store/$pkg/share/kde4/services/kded) saying basically “Hi, my name is $name, autoload me”. Later you can overwrite those autoload directives in your kdedrc. As far as I can tell, those files will be merged (bottom-up): ~/.kde/share/config/kdedrc ~/.nix-profile/share/config/kdedrc /nix/var/nix/profiles/default/share/config/kdedrc /run/current-system/sw/share/config/kdedrc /nix/store/$kdelibs/share/config/kdedrc /nix/store/$kde-workspace/share/config/kdedrc (please, correct me if I got something wrong, as I'm not a KDE expert, and especially not a KDE-on-NixOS expert) So, here is what we have. Just installing KScreen will result in both randrmonitor and kscreen being autoloaded which is a bad thing. It seems reasonable to me to create a kdedrc during installPhase that will disable randrmonitor, this way the file will go either to /run/current-system/sw/share/config/ or to ~/.nix-profile/share/config/kdedrc. Is that acceptable? Bad things might happen if, for some reason, there is autoload=true for randrmonitor in ~/.kde/share/config/kdedrc. I should note that on my Gentoo box _indeed_ that was the case, but I have no idea how did this happen. On my NixOS box this file is effectively empty, which is good news. So far I was talking only about step number 2. Now back to 1 and 3. In case of per-user install, is there a way to perform this kind of “activation”—make a dbus call? Is that acceptable? The same question about “deactivation” on removal (again, two calls: unload kscreen, load randrmonitor back). In case of system-wide install, is there a way to perform this kind of activation? The issue is that it involves dbus calls on session bus (ideally, for every logged on user). -- Кирилл Елагин
_______________________________________________ nix-dev mailing list nix-dev@lists.science.uu.nl http://lists.science.uu.nl/mailman/listinfo/nix-dev