mirror of
https://github.com/kmein/niveum
synced 2026-03-21 20:31:07 +01:00
feat(mutt): add archive wrapper
This commit is contained in:
@@ -11,6 +11,12 @@ let
|
|||||||
neomutt.enable = true;
|
neomutt.enable = true;
|
||||||
notmuch.enable = false;
|
notmuch.enable = false;
|
||||||
};
|
};
|
||||||
|
addArchiveCommand = folder: lib.recursiveUpdate {
|
||||||
|
neomutt.extraConfig = ''
|
||||||
|
# named-mailboxes " └Archive" "=${folder}"
|
||||||
|
macro pager,index \' "<save-message>+${folder}<enter>" "Archive"
|
||||||
|
'';
|
||||||
|
};
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
environment.systemPackages = [ pkgs.neomutt ];
|
environment.systemPackages = [ pkgs.neomutt ];
|
||||||
@@ -18,7 +24,7 @@ in
|
|||||||
home-manager.users.me = let maildir = "${config.users.users.me.home}/mail"; in {
|
home-manager.users.me = let maildir = "${config.users.users.me.home}/mail"; in {
|
||||||
accounts.email.maildirBasePath = maildir;
|
accounts.email.maildirBasePath = maildir;
|
||||||
accounts.email.accounts = {
|
accounts.email.accounts = {
|
||||||
cock = enableDefaults {
|
cock = addArchiveCommand "Archive" (enableDefaults {
|
||||||
primary = false;
|
primary = false;
|
||||||
smtp = {
|
smtp = {
|
||||||
host = "mail.cock.li";
|
host = "mail.cock.li";
|
||||||
@@ -34,24 +40,21 @@ in
|
|||||||
address = "2210@cock.li";
|
address = "2210@cock.li";
|
||||||
realName = "2210";
|
realName = "2210";
|
||||||
passwordCommand = pass "mail/2210@cock.li";
|
passwordCommand = pass "mail/2210@cock.li";
|
||||||
};
|
});
|
||||||
kieran-gmail = enableDefaults {
|
kieran-gmail = addArchiveCommand "[Gmail]/Alle Nachrichten" (enableDefaults {
|
||||||
primary = true;
|
primary = true;
|
||||||
flavor = "gmail.com";
|
flavor = "gmail.com";
|
||||||
address = "kieran.meinhardt@gmail.com";
|
address = "kieran.meinhardt@gmail.com";
|
||||||
realName = config.niveum.user.name;
|
realName = config.niveum.user.name;
|
||||||
userName = "kieran.meinhardt";
|
userName = "kieran.meinhardt";
|
||||||
passwordCommand = pass "mail/kieran.meinhardt@gmail.com";
|
passwordCommand = pass "mail/kieran.meinhardt@gmail.com";
|
||||||
neomutt.extraConfig = ''
|
|
||||||
macro pager,index \' "<save-message>+[Gmail]/Alle Nachrichten<enter>" "Archive"
|
|
||||||
'';
|
|
||||||
folders = {
|
folders = {
|
||||||
drafts = "[Gmail]/Entw&APw-rfe";
|
drafts = "[Gmail]/Entw&APw-rfe";
|
||||||
sent = "[Gmail]/Gesendet";
|
sent = "[Gmail]/Gesendet";
|
||||||
trash = "[Gmail]/Papierkorb";
|
trash = "[Gmail]/Papierkorb";
|
||||||
};
|
};
|
||||||
};
|
});
|
||||||
hu-berlin = enableDefaults {
|
hu-berlin = addArchiveCommand "Archives" (enableDefaults {
|
||||||
primary = false;
|
primary = false;
|
||||||
address = "meinhark@hu-berlin.de";
|
address = "meinhark@hu-berlin.de";
|
||||||
realName = config.niveum.user.name;
|
realName = config.niveum.user.name;
|
||||||
@@ -67,10 +70,7 @@ in
|
|||||||
port = 993;
|
port = 993;
|
||||||
tls.enable = true;
|
tls.enable = true;
|
||||||
};
|
};
|
||||||
neomutt.extraConfig = ''
|
});
|
||||||
macro pager,index \' "<save-message>Archives<enter>" "Archive"
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
|
|
||||||
programs.neomutt = {
|
programs.neomutt = {
|
||||||
|
|||||||
Reference in New Issue
Block a user