From e5ac92e351c3aee07754dcbb155545b39c032205 Mon Sep 17 00:00:00 2001 From: Madeline Hashcube Date: Sat, 26 Sep 2026 22:53:06 -0500 Subject: [PATCH] feat!: use mu4e for email BREAKING CHANGES: aerc is no longer used for emailing --- README.md | 2 +- users/hashcube/emacs.el | 16 ++++++++++++++++ users/hashcube/emacs.nix | 1 + users/hashcube/email.nix | 19 +++++-------------- users/hashcube/programs/display/niri.nix | 4 ++-- 5 files changed, 25 insertions(+), 17 deletions(-) diff --git a/README.md b/README.md index 00dd494..28c621e 100644 --- a/README.md +++ b/README.md @@ -41,7 +41,7 @@ The important XF86 Keys just work as intended | `Mod`+`.` | Open App Picker | | `Mod`+`Q` | Close Window | | `Mod`+`W` | Open Overview | -| `Mod`+`E` | Open Aerc | +| `Mod`+`E` | Open Emacs | | `Mod`+`R` | Open Nautilus | | `Mod`+`T` | Open Kitty | | `Mod`+`A` | Tile Focused Window | diff --git a/users/hashcube/emacs.el b/users/hashcube/emacs.el index d7e1f45..15bf838 100644 --- a/users/hashcube/emacs.el +++ b/users/hashcube/emacs.el @@ -17,6 +17,22 @@ (column-number-mode 1) (show-paren-mode 1) +;; Setup Email Things +(setq mail-user-agent 'mu4e) +(setq mu4e-get-mail-command "offlineimap") +(setq message-kill-buffer-on-exit t) +(setq user-mail-address "madeline@hashcube.dev" + user-full-name "Madeline Hashcube") +(setq + message-send-mail-function 'smtpmail-send-it + smtpmail-servers-requiring-authorization "smtp.porkbun.com" + smtpmail-default-smtp-server "smtp.porkbun.com" + smtpmail-smtp-user "madeline@hashcube.dev" + smtpmail-smtp-server "smtp.porkbun.com" + smtpmail-smtp-service 465 + smtpmail-stream-type 'tls + smtpmail-local-domain "hashcube.dev") + ;; Enable Company Mode (add-hook 'after-init-hook 'global-company-mode) ;; (add-hook 'nix-mode-hook (lambda () diff --git a/users/hashcube/emacs.nix b/users/hashcube/emacs.nix index 9ddc208..92a4363 100644 --- a/users/hashcube/emacs.nix +++ b/users/hashcube/emacs.nix @@ -15,6 +15,7 @@ dired-sidebar helm vterm + mu4e # company mode company diff --git a/users/hashcube/email.nix b/users/hashcube/email.nix index 3f9daee..5eea6ed 100644 --- a/users/hashcube/email.nix +++ b/users/hashcube/email.nix @@ -1,31 +1,22 @@ { inputs, ... }: { - programs.aerc = { - enable = true; - extraConfig = { - general.unsafe-accounts-conf = true; - filters = { - "text/plain" = "colorize"; - "text/html" = "! w3m -I UTF-8 -T text/html"; - }; - }; - }; + programs.offlineimap.enable = true; accounts.email.accounts = { # very epic and cool email >:3c "hashcube.dev" = { enable = true; primary = true; realName = "Madeline Hashcube"; - passwordCommand = "op item get \"Porkbun Email\" --fields label=password --reveal"; + passwordCommand = [ "op" "item" "get" "3e2hlipy4dxrknajkfi6pcergm" "--fields" "label=password" "--reveal" ]; + address = "madeline@hashcube.dev"; # because git userName = "madeline@hashcube.dev"; flavor = "plain"; - aerc = { - enable = true; - }; + offlineimap.enable = true; + mu.enable = true; folders = let prefix = "INBOX."; in { inbox = "INBOX"; diff --git a/users/hashcube/programs/display/niri.nix b/users/hashcube/programs/display/niri.nix index b2ae811..401f813 100644 --- a/users/hashcube/programs/display/niri.nix +++ b/users/hashcube/programs/display/niri.nix @@ -96,8 +96,8 @@ spawn = term ''nu''; }; "Mod+E" = { - _props.hotkey-overlay-title = "Open Aerc (Email)"; - spawn = term "aerc"; + _props.hotkey-overlay-title = "Open Emacs"; + spawn-sh = [ "emacsclient" "-c" "-a" "\"\"" ]; }; "Mod+R" = { _props.hotkey-overlay-title = "Open Nautilus (Files)"; -- 2.51.2