{ pkgs, config, inputs, lib, ... }: let cfg = config.xyno.common; in { options.xyno.common.enable = lib.mkEnableOption "enables common settings"; config = lib.mkIf cfg.enable { boot.initrd.systemd.enable = true; hardware.keyboard.zsa.enable = true; programs.nh.enable = true; # patch in auth_keep for run0 security.polkit.extraConfig = '' polkit.addRule(function(action, subject) { // make run0 keep pw for some time (tm) if ( subject.isInGroup("wheel") && action.id == "org.freedesktop.systemd1.manage-units" ) { return polkit.Result.YES; } }); ''; }; }