fork/home-manager

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

Robert HelgessonMerge PR #421575790441

master
1.3 KiB48 linesraw
1{ config, lib, ... }:
2
3with lib;
4
5{
6  options.msmtp = {
7    enable = mkOption {
8      type = types.bool;
9      default = false;
10      description = ''
11        Whether to enable msmtp.
12
13        If enabled then it is possible to use the
14        `--account` command line
15        option to send a message for a given account using the
16        {command}`msmtp` or {command}`msmtpq` tool.
17        For example, {command}`msmtp --account=private` would
18        send using the account defined in
19        {option}`accounts.email.accounts.private`. If the
20        `--account` option is not
21        given then the primary account will be used.
22      '';
23    };
24
25    tls.fingerprint = mkOption {
26      type =
27        types.nullOr (types.strMatching "([[:alnum:]]{2}:)+[[:alnum:]]{2}");
28      default = null;
29      example = "my:SH:a2:56:ha:sh";
30      description = ''
31        Fingerprint of a trusted TLS certificate.
32        The fingerprint can be obtained by executing
33        {command}`msmtp --serverinfo --tls --tls-certcheck=off`.
34      '';
35    };
36
37    extraConfig = mkOption {
38      type = types.attrsOf types.str;
39      default = { };
40      example = { auth = "login"; };
41      description = ''
42        Extra configuration options to add to {file}`~/.msmtprc`.
43        See <https://marlam.de/msmtp/msmtprc.txt> for
44        examples.
45      '';
46    };
47  };
48}