1
0
Fork 0
mirror of https://github.com/nix-community/home-manager synced 2024-11-23 03:29:45 +01:00

programs/alot: make Sent and Drafts folder optional (#3798)

Some of the email providers (like GMail and Fastmail) save Sent messages
automatically, so make the folders optional in the configuration.

Make Drafts folder optional as well, to allow it to be configured
manually in the extraConf with location outside of the maildir.
This commit is contained in:
Pavel Borzenkov 2023-03-22 13:25:02 +03:00 committed by GitHub
parent c6a7bc90ca
commit 363c46b248
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 1 deletions

View file

@ -321,7 +321,7 @@ let
};
drafts = mkOption {
type = types.str;
type = types.nullOr types.str;
default = "Drafts";
description = ''
Relative path of the drafts mail folder.

View file

@ -68,7 +68,9 @@ let
realname = realName;
sendmail_command =
optionalString (alot.sendMailCommand != null) alot.sendMailCommand;
} // optionalAttrs (folders.sent != null) {
sent_box = "maildir" + "://" + maildir.absPath + "/" + folders.sent;
} // optionalAttrs (folders.drafts != null) {
draft_box = "maildir" + "://" + maildir.absPath + "/" + folders.drafts;
} // optionalAttrs (aliases != [ ]) {
aliases = concatStringsSep "," aliases;