2022-10-24 13:12:54 +01:00
|
|
|
{ config, lib, ... }:
|
|
|
|
|
|
|
|
with lib;
|
|
|
|
|
2025-03-08 09:36:15 -07:00
|
|
|
let
|
|
|
|
valueType = with lib.types; nullOr (oneOf [
|
|
|
|
bool
|
|
|
|
int
|
|
|
|
float
|
|
|
|
str
|
|
|
|
path
|
|
|
|
(attrsOf valueType)
|
|
|
|
(listOf valueType)
|
|
|
|
]) // {
|
|
|
|
description = "plist value";
|
|
|
|
};
|
|
|
|
defaultsType = types.submodule {
|
|
|
|
freeformType = valueType;
|
|
|
|
};
|
|
|
|
in {
|
2022-10-24 13:12:54 +01:00
|
|
|
options = {
|
|
|
|
system.defaults.CustomUserPreferences = mkOption {
|
2025-03-08 09:36:15 -07:00
|
|
|
type = defaultsType;
|
2022-10-24 13:12:54 +01:00
|
|
|
default = { };
|
|
|
|
example = {
|
|
|
|
"NSGlobalDomain" = { "TISRomanSwitchState" = 1; };
|
|
|
|
"com.apple.Safari" = {
|
|
|
|
"com.apple.Safari.ContentPageGroupIdentifier.WebKit2DeveloperExtrasEnabled" =
|
|
|
|
true;
|
|
|
|
};
|
|
|
|
};
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2022-10-24 13:12:54 +01:00
|
|
|
Sets custom user preferences
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
|
|
|
system.defaults.CustomSystemPreferences = mkOption {
|
2025-03-08 09:36:15 -07:00
|
|
|
type = defaultsType;
|
2022-10-24 13:12:54 +01:00
|
|
|
default = { };
|
|
|
|
example = {
|
|
|
|
"NSGlobalDomain" = { "TISRomanSwitchState" = 1; };
|
|
|
|
"com.apple.Safari" = {
|
|
|
|
"com.apple.Safari.ContentPageGroupIdentifier.WebKit2DeveloperExtrasEnabled" =
|
|
|
|
true;
|
|
|
|
};
|
|
|
|
};
|
2024-04-14 23:02:32 +02:00
|
|
|
description = ''
|
2022-10-24 13:12:54 +01:00
|
|
|
Sets custom system preferences
|
|
|
|
'';
|
|
|
|
};
|
|
|
|
|
|
|
|
};
|
|
|
|
}
|