# SPDX-FileCopyrightText: 2025 Ethan Reece # # SPDX-License-Identifier: MIT { config, flakeConfig, pkgs, ... }: { # imports = [ # ../email.nix # ./secrets.nix # ]; # accounts.email.accounts = { # # https://github.com/lajp/nix/blob/main/modules/user/accounts.nix # # Use Thunderbird tokens and `mutt_oauth2.py` to authenticate # utdallas = # let # realName = flakeConfig.profiles.utdallas.names.default; # address = flakeConfig.profiles.utdallas.emails.default; # in # { # inherit realName; # inherit address; # msmtp = { # enable = true; # extraConfig.auth = "xoauth2"; # }; # # TODO: Fix GPG # passwordCommand = # let # python = "${pkgs.python3}/bin/python3"; # mutt_oauth2 = "${pkgs.neomutt}/share/neomutt/oauth2/mutt_oauth2.py"; # passDir = config.programs.password-store.settings.PASSWORD_STORE_DIR; # in # "${python} ${mutt_oauth2} --encryption-pipe 'gpg -e -r ${address}' ${passDir}/${address}.gpg"; # gpg = { # signByDefault = true; # }; # flavor = "outlook.office365.com"; # mbsync = { # enable = true; # create = "maildir"; # expunge = "maildir"; # extraConfig.account.AuthMechs = "XOAUTH2"; # }; # neomutt = { # enable = true; # }; # maildir.path = address; # notmuch = { # enable = true; # neomutt.enable = true; # }; # }; # }; }