# LibreWolf browser. The package is an option so a consumer can swap the wrapped # package without editing this module: the base is plain pkgs.librewolf, but the # wrapper (wrapFirefox) accepts `extraPolicies` and `extraPrefs`, and overriding # those is the clean way to manage LibreWolf declaratively. # # The useful case is sharing state across LibreWolf profiles that otherwise stay # separate (each `-P ` has its own history/logins/cookies). Enterprise # policy `ExtensionSettings` force- or normal-installs the same add-ons into # every profile, and `extraPrefs` (autoconfig `defaultPref`/`lockPref`) seeds a # shared about:config baseline — both applied per-launch, neither touching # per-profile user data. Override, e.g.: # # local.librewolf.package = pkgs.librewolf.override { # extraPolicies.ExtensionSettings."uBlock0@raymondhill.net" = { # installation_mode = "normal_installed"; # install_url = "https://addons.mozilla.org/firefox/downloads/latest/ublock-origin/latest.xpi"; # }; # extraPrefs = ''defaultPref("browser.startup.page", 3);''; # }; { config, lib, pkgs, ... }: { options.local.librewolf.package = lib.mkOption { type = lib.types.package; default = pkgs.librewolf; defaultText = lib.literalExpression "pkgs.librewolf"; description = '' LibreWolf package. Override with `pkgs.librewolf.override { extraPolicies = …; extraPrefs = …; }` to share extensions/settings across profiles. ''; }; config.home.packages = [ config.local.librewolf.package ]; }