about summary refs log tree commit diff
path: root/users/glittershark/system/home/modules/email.nix
diff options
context:
space:
mode:
authorGriffin Smith <grfn@gws.fyi>2021-04-01T16·37-0400
committerglittershark <grfn@gws.fyi>2021-04-03T18·54+0000
commited7240ade52532048e08ff9be80b0fc99ea1e82c (patch)
tree71968a2cc6b4b5336070cc6fb9667c4b177ca802 /users/glittershark/system/home/modules/email.nix
parente908ccdbbbe60ba2dfecfb0bad37352d79f8527d (diff)
feat(gs/home): Set up lieer for work email r/2414
Change-Id: I49d6c8450b87cc876e93cba150327b5612eeebc3
Reviewed-on: https://cl.tvl.fyi/c/depot/+/2801
Reviewed-by: glittershark <grfn@gws.fyi>
Tested-by: BuildkiteCI
Diffstat (limited to 'users/glittershark/system/home/modules/email.nix')
-rw-r--r--users/glittershark/system/home/modules/email.nix19
1 files changed, 14 insertions, 5 deletions
diff --git a/users/glittershark/system/home/modules/email.nix b/users/glittershark/system/home/modules/email.nix
index 77e068f43fbb..cdfcbecb7c00 100644
--- a/users/glittershark/system/home/modules/email.nix
+++ b/users/glittershark/system/home/modules/email.nix
@@ -1,4 +1,4 @@
-{ lib, pkgs, ... }:
+{ lib, pkgs, config, ... }:
 
 with lib;
 
@@ -18,6 +18,12 @@ let
       aliases = [ "grfn@gws.fyi" ];
       passEntry = "root-gws-msmtp";
     };
+
+    work = {
+      address = "griffin@readyset.io";
+      passEntry = "readyset/msmtp";
+    };
+
   };
 
 in {
@@ -37,10 +43,13 @@ in {
 
   systemd.user.services = mapAttrs' (name: account: {
     name = escapeUnitName "lieer-${name}";
-    value.Service.ExecStart = mkForce "${pkgs.writeShellScript "sync-${name}" ''
-      ${pkgs.gmailieer}/bin/gmi sync
-    ''}";
-    # ${pkgs.notifymuch}/bin/notifymuch
+    value.Service = {
+      ExecStart = mkForce "${pkgs.writeShellScript "sync-${name}" ''
+        ${pkgs.gmailieer}/bin/gmi sync --path ~/mail/${name}
+      ''}";
+      Environment = "NOTMUCH_CONFIG=${config.home.sessionVariables.NOTMUCH_CONFIG}";
+    };
+
   }) accounts;
 
   # xdg.configFile."notifymuch/notifymuch.cfg".text = generators.toINI {} {