nixos-config/modules/desktop/firefox.nix

59 lines
2 KiB
Nix
Raw Normal View History

2024-11-08 03:59:57 +00:00
{
config,
lib,
pkgs,
...
}:
2023-07-27 17:35:44 +00:00
{
2023-11-11 19:02:01 +00:00
config = lib.mkIf (config.sconfig.desktop.enable) {
environment.systemPackages = [
(pkgs.wrapFirefox pkgs.firefox-unwrapped {
extraPolicies = {
NewTabPage = false;
CaptivePortal = false;
DisablePocket = true;
DisableFirefoxAccounts = true;
DisableFirefoxStudies = true;
OfferToSaveLogins = false;
DisableFormHistory = true;
SearchSuggestEnabled = false;
2024-11-08 03:59:57 +00:00
Preferences =
2023-11-11 19:02:01 +00:00
builtins.mapAttrs
2024-11-08 03:59:57 +00:00
(n: v: {
Value = v;
Status = "locked";
})
{
"accessibility.force_disabled" = 1;
"browser.aboutConfig.showWarning" = false;
"browser.contentblocking.category" = "strict";
"browser.tabs.firefox-view" = false;
"browser.uitour.enabled" = false;
"browser.zoom.siteSpecific" = false;
"extensions.formautofill.addresses.enabled" = false;
"extensions.formautofill.creditCards.enabled" = false;
"extensions.formautofill.heuristics.enabled" = false;
"network.IDN_show_punycode" = true;
"places.history.expiration.max_pages" = 2048;
"ui.key.menuAccessKeyFocuses" = false;
};
ExtensionSettings =
{
"*".installation_mode = "blocked";
}
// builtins.mapAttrs
2023-11-11 19:02:01 +00:00
(n: v: {
installation_mode = "force_installed";
install_url = "https://addons.mozilla.org/firefox/downloads/latest/${v}/latest.xpi";
})
{
"jid1-KKzOGWgsW3Ao4Q@jetpack" = "i-dont-care-about-cookies";
"{446900e4-71c2-419f-a6a7-df9c091e268b}" = "bitwarden-password-manager";
2024-02-16 04:18:46 +00:00
"{d7742d87-e61d-4b78-b8a1-b469842139fa}" = "vimium-ff";
2023-11-11 19:02:01 +00:00
};
};
})
];
};
2023-07-27 17:35:44 +00:00
}