blob: 3aa1814ca19a4e7e085addafc3414ff13dc851b0 (
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
|
{ pkgs, ... }:
{
home-manager.users.makefu = {
home.packages= with pkgs;[ (pkgs.writers.writeDashBin "mailsync"''
${imapfilter}/bin/imapfilter -t /etc/ssl/certs/ca-bundle.crt \
&& ${isync}/bin/mbsync -a \
&& ${libnotify}/bin/notify-send -t 1000000 -u critical 'Mail sync finished'
''
)];
programs.mbsync.enable = true;
accounts.email.maildirBasePath = "/home/makefu/Mail";
accounts.email.certificatesFile = "/etc/ssl/certs/ca-certificates.crt";
accounts.email.accounts.syntaxfehler = {
address = "felix.richter@syntax-fehler.de";
userName = "Felix.Richter@syntax-fehler.de";
imap = {
host = "syntax-fehler.de";
tls = {
enable = true;
};
};
mbsync = {
enable = true;
create = "both";
remove = "both";
expunge = "both";
patterns = [ "*" "!INBOX.Sent*"];
};
smtp = {
host = "syntax-fehler.de";
tls = {
enable = true;
};
};
folders = {
sent = "Sent";
trash = "Trash";
inbox = "INBOX";
drafts = "Drafts";
};
msmtp.enable = true;
notmuch.enable = true;
offlineimap = {
enable = true;
postSyncHookCommand = "notmuch new";
extraConfig.remote = {
auth_mechanisms = "LOGIN";
tls_level = "tls_secure";
ssl_version = "tls1_2";
holdconnectionopen = true;
idlefolders = "['INBOX']";
};
};
primary = true;
realName = "Felix Richter";
passwordCommand = "gpg --use-agent --quiet --batch -d /home/makefu/.gnupg/mail/syntax-fehler.gpg";
};
programs.offlineimap.enable = true;
programs.offlineimap.extraConfig = {
mbnames = {
filename = "~/.mutt/muttrc.mailboxes";
header = "'mailboxes '";
peritem = "'+%(accountname)s/%(foldername)s'";
sep = "' '";
footer = "'\\n'";
};
general = {
ui = "TTY.TTYUI";
};
};
};
}
|