1
0
Fork 0
mirror of https://github.com/LnL7/nix-darwin.git synced 2024-12-14 11:57:34 +00:00

khd: add option to enable accessibility permissions

This commit is contained in:
Daiderd Jordan 2017-05-16 00:32:11 +02:00
parent 5a220c5249
commit 7f7d4bfebd
No known key found for this signature in database
GPG key ID: D02435D05B810C96

View file

@ -21,14 +21,23 @@ in
example = literalExample "pkgs.khd";
description = "This option specifies the khd package to use.";
};
services.khd.enableAccessibilityAccess = mkOption {
type = types.bool;
default = false;
description = "Whether to enable accessibility permissions for the khd daemon.";
};
};
config = mkIf cfg.enable {
services.khd.package = mkDefault pkgs.khd;
security.accessibilityPrograms = [ "${cfg.package}/bin/khd" ];
launchd.user.agents.khd = {
path = [ cfg.package pkgs.kwm config.environment.systemPath ];
serviceConfig.Program = "${cfg.package}/bin/khd";
serviceConfig.KeepAlive = true;
serviceConfig.ProcessType = "Interactive";