aboutsummaryrefslogtreecommitdiff
path: root/modules/firefox.nix
blob: 8423ec4ad5b06f43901e114cf11b845baf12dcd9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
{ config, lib, pkgs, ... }:

let
  cfg = config.firefox;
in {
  options.enable = lib.mkEnableOption = "Setup firefox";

  config = lib.mkIf cfg.enable {
    program.firefox = {
      enable = true;
      extensions = with pkgs.nur.repos.rycee.firefox-addons; [
        ublock-origin
	istilldontcareaboutcookies
	sponsorblock
	vimium-c
	startpage-private-search
      ];

      userProfile = {
        preferences = {
	  # Disable the Bookmarks Toolbar
	  "browser.toolbars.bookmarks.visibility" = "never";
	  
	  # Disable Pocket
	  "extensions.pocket.enabled" = false;

	  # Remove Firefox View
	  "browser.newtabpage.activity-stream.showSponsored" = false;
          "browser.newtabpage.activity-stream.showSearch" = false;
          "browser.newtabpage.activity-stream.showTopSites" = false;
          "browser.newtabpage.activity-stream.showHighlights" = false;

	  # privacy settings
	  "privacy.firstparty.isolate" = true;  # Isolate cookies per site
          "privacy.resistFingerprinting" = true;
          "privacy.trackingprotection.enabled" = true;
        };
      };
    };
  };
}