thunderbird: support setting search engines (#5697)

* firefox: split search into separate submodule file

* thunderbird: support setting search engines
This commit is contained in:
Kira Bruneau
2024-10-14 07:01:26 -04:00
committed by GitHub
parent 64c6325b28
commit e1aec543f5
4 changed files with 288 additions and 236 deletions

View File

@@ -225,6 +225,20 @@ in {
Extra preferences to add to {file}`user.js`.
'';
};
search = mkOption {
type = types.submodule (args:
import ./firefox/profiles/search.nix {
inherit (args) config;
inherit lib pkgs;
appName = "Thunderbird";
modulePath =
[ "programs" "thunderbird" "profiles" name "search" ];
profilePath = name;
});
default = { };
description = "Declarative search engine configuration.";
};
};
}));
description = "Attribute set of Thunderbird profiles.";
@@ -393,6 +407,12 @@ in {
] ++ (map (a: toThunderbirdAccount a profile) accounts)))
profile.extraConfig;
};
"${thunderbirdProfilesPath}/${name}/search.json.mozlz4" = {
enable = profile.search.enable;
force = profile.search.force;
source = profile.search.file;
};
}));
};
}