feat(firefox): set search engines through policies

This commit is contained in:
Moritz Böhme 2023-12-11 16:55:24 +01:00
parent 82ffbcbde4
commit e7fd307bfb
Signed by: moritz
GPG key ID: 970C6E89EB0547A9

View file

@ -29,11 +29,21 @@ in
);
};
};
setSearchEngines = mkEnableOption "firefox search engines" // {
default = true;
};
};
config = mkIf cfg.enable {
home-manager.users.moritz.programs.firefox = {
enable = true;
policies = mkIf cfg.setSearchEngines {
SearchEngines = {
Default = "Kagi";
Remove = [ "Google" "Amazon.de" "Bing" ];
};
};
package = if cfg.setSearchEngines then pkgs.firefox-esr else pkgs.firefox;
profiles."default" = {
extraConfig = mkIf cfg.arkenfox.enable ''
// Arkenfox user.js