summary refs log tree commit diff stats
path: root/emacs
diff options
context:
space:
mode:
authorAlan Pearce2019-08-05 14:46:37 +0200
committerAlan Pearce2019-08-05 14:46:37 +0200
commite275653231e711a4ede34babdb855913b6a80667 (patch)
treea55bf0336b4bcfed564fb070ff11305dbdc3a894 /emacs
parented576d210eb911c4cb0d0babb456e9e463284389 (diff)
downloadnixfiles-e275653231e711a4ede34babdb855913b6a80667.tar.lz
nixfiles-e275653231e711a4ede34babdb855913b6a80667.tar.zst
nixfiles-e275653231e711a4ede34babdb855913b6a80667.zip
Re-add e-mail setup
Diffstat (limited to 'emacs')
-rw-r--r--emacs/.emacs.d/main.el28
1 files changed, 28 insertions, 0 deletions
diff --git a/emacs/.emacs.d/main.el b/emacs/.emacs.d/main.el
index 1c8e78a4..686cc6f9 100644
--- a/emacs/.emacs.d/main.el
+++ b/emacs/.emacs.d/main.el
@@ -639,6 +639,34 @@ With two prefix arguments, write out the day and month name."
                       prettier-js-args '("--pkg-conf"))
               (message "prettier_d is not available"))))
 
+;;; E-mail
+
+(use-package mu4e
+  :init (setq mail-user-agent #'mu4e-user-agent)
+  :custom ((mu4e-completing-read-function #'ivy-completing-read)
+           (mu4e-maildir "~/mail")
+           (mu4e-compose-format-flowed t))
+  :config (progn
+            (with-eval-after-load 'evil-ex
+              (evil-ex-define-cmd "mu[4e]" #'mu4e))
+            (setq mu4e-contexts (list
+                                 (make-mu4e-context
+                                  :name "SatoshiPay"
+                                  :match-func (lambda (msg)
+                                                (when msg
+                                                  (mu4e-message-contact-field-matches
+                                                   msg :to "alan@satoshipay.io")))
+                                  :vars '((user-mail-address . "alan@satoshipay.io")
+                                          (mu4e-sent-messages-behavior . 'delete)
+                                          (mu4e-drafts-folder . "/satoshipay/Drafts")
+                                          (mu4e-sent-folder . "/satoshipay/Sent Mail")
+                                          (mu4e-refile-folder . "/satoshipay/All Mail")
+                                          (mu4e-trash-folder . "/satoshipay/Bin")
+                                          (mu4e-maildir-shortcuts . (("/satoshipay/INBOX" . ?i)
+                                                                     ("/satoshipay/All Mail" . ?a)
+                                                                     ("/satoshipay/Sent Mail" . ?s)
+                                                                     ("/satoshipay/Spam" . ?p)))))))))
+
 ;;; Take me to my leader
 
 (my-leader-def