65 lines
1.8 KiB
Nix
Raw Normal View History

2022-12-14 23:49:46 +03:00
{ config, pkgs, lib, ... }: {
2021-10-31 15:56:30 +03:00
2022-12-10 22:34:39 +03:00
home-manager.users.${config.mainuser} = {
2021-10-31 15:56:30 +03:00
home.packages = [ pkgs.himalaya ];
xdg.configFile."himalaya/config.toml".text = ''
2023-03-27 16:00:57 +03:00
downloads-dir = "/home/${config.mainuser}/Downloads/mail"
name = "Dmitriy Kholkin"
signature = "Regards,"
# email-reading-verify-cmd
# email-reading-decrypt-cmd
# email-writing-sign-cmd
# email-writing-encrypt-cmd
# notify-cmd
# notify-query
# sync
2021-10-31 15:56:30 +03:00
[ataraxiadev]
2023-03-27 16:00:57 +03:00
default = true
email = "ataraxiadev@ataraxiadev.com"
backend = "imap"
imap-host = "mail.ataraxiadev.com"
imap-port = 993
imap-login = "ataraxiadev@ataraxiadev.com"
imap-passwd-cmd = "${pkgs.pass}/bin/pass show email/ataraxiadev@ataraxiadev.com"
imap-ssl = true
imap-starttls = false
imap-insecure = false
sender = "smtp"
smtp-host = "mail.ataraxiadev.com"
smtp-port = 465
smtp-login = "ataraxiadev@ataraxiadev.com"
smtp-passwd-cmd = "${pkgs.pass}/bin/pass show email/ataraxiadev@ataraxiadev.com"
smtp-ssl = true
smtp-starttls = false
smtp-insecure = false
2021-10-31 15:56:30 +03:00
'';
};
2023-03-27 16:00:57 +03:00
2023-03-27 20:57:06 +03:00
systemd.user.services.himalaya-notify = {
description = "Himalaya new messages notifier";
after = [ "network.target" ];
wantedBy = [ "default.target" ];
script = "himalaya notify";
environment = {
PASSWORD_STORE_DIR = config.secretsConfig.password-store;
GNUPGHOME = config.secretsConfig.gnupgHome;
};
# script = "echo $(pass show email/ataraxiadev@ataraxiadev.com) || echo lol";
path = with pkgs; [ himalaya libnotify pass gnupg ];
serviceConfig = {
Restart = lib.mkForce "no";
# Restart = "always";
RestartSec = 10;
# Type = "oneshot";
};
};
2023-03-27 16:00:57 +03:00
persist.state.homeDirectories = [
".config/himalaya"
];
2021-10-31 15:56:30 +03:00
}