summaryrefslogtreecommitdiff
path: root/modules/home-manager/personal/programs/thunderbird/default.nix
blob: 64333bcc53df52ab9fffa92d0aa8b5565ee408a6 (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
{
  config,
  lib,
  ...
}:
{
  imports = [
    ./extensions.nix
    ./userjs.nix
  ];

  config = lib.mkMerge [
    {
      programs.thunderbird = {
        profiles.default = {
          isDefault = true;
          withExternalGnupg = true;
        };
      };
    }
    (lib.mkIf config.programs.thunderbird.enable {
      xdg.mimeApps.defaultApplications = {
        "x-scheme-handler/mailto" = [ "thunderbird.desktop" ];
        "text/calendar" = [ "thunderbird.desktop" ];
        "application/x-xpinstall" = [ "thunderbird.desktop" ];
      };
    })
  ];
}