{ pkgs, ... }: let gpgid = "D09299626FA78AF8"; homedir = builtins.getEnv "HOME"; in { #nixpkgs.overlays = [ # (self: super: { # notmuch = pkgs.callPackage ../pkgs/notmuch.nix {}; # }) #]; accounts = { email = { maildirBasePath = "${homedir}/Mail"; accounts = { "ben@simatime.com" = { primary = true; realName = "Ben Sima"; address = "ben@bsima.me"; userName = "ben@simatime.com"; # alot is broken in nixpkgs 21.11 #alot.sendMailCommand = "${homedir}/bin/sendmail"; imap = { host = "simatime.com"; port = 993; }; smtp = { host = "simatime.com"; port = 587; tls = { enable = true; useStartTls = true; }; }; gpg = { key = gpgid; signByDefault = true; encryptByDefault = false; }; mbsync = { enable = true; create = "both"; expunge = "none"; }; notmuch.enable = true; passwordCommand = "${pkgs.coreutils}/bin/cat ~/private/ben@simatime.com"; msmtp.enable = true; }; # "ben@heroprojects.io" = { # flavor = "gmail.com"; # realName = "Ben Sima"; # address = "ben@heroprojects.io"; # userName = "ben@heroprojects.io"; # mbsync = { # enable = true; # create = "both"; # expunge = "none"; # }; # notmuch.enable = true; # msmtp.enable = true; # passwordCommand = "cat ~/keybase/private/bsima/ben@heroprojects.io"; # }; }; }; }; programs = { notmuch = { enable = true; new.tags = [ "new" ]; hooks = { postNew = "${pkgs.afew}/bin/afew -tn && ${pkgs.afew}/bin/afew -t tag:inbox"; }; extraConfig = { search = { exclude_tags = "deleted;spam;"; }; }; }; afew = { enable = true; extraConfig = builtins.readFile ./afew.ini; }; #alot = { # enable = true; # extraConfig = '' # theme = solarized_light # ''; #}; mbsync = { enable = true; }; msmtp = { enable = true; }; }; }