fork/home-manager

git clone https://git.julia.blue/fork/home-manager

Robert HelgessonMerge PR #421575790441

master
782 B32 linesraw
1{ config, lib, ... }:
2
3with lib;
4
5{
6  options.astroid = {
7    enable = mkEnableOption "Astroid";
8
9    sendMailCommand = mkOption {
10      type = types.str;
11      description = ''
12        Command to send a mail. If msmtp is enabled for the account,
13        then this is set to
14        {command}`msmtpq --read-envelope-from --read-recipients`.
15      '';
16    };
17
18    extraConfig = mkOption {
19      type = types.attrsOf types.anything;
20      default = { };
21      example = { select_query = ""; };
22      description = ''
23        Extra settings to add to this astroid account configuration.
24      '';
25    };
26  };
27
28  config = mkIf config.notmuch.enable {
29    astroid.sendMailCommand = mkIf config.msmtp.enable
30      (mkOptionDefault "msmtpq --read-envelope-from --read-recipients");
31  };
32}