71 lines
2.9 KiB
EmacsLisp
71 lines
2.9 KiB
EmacsLisp
(setq sendmail-program (executable-find "msmtp")
|
|
send-mail-function #'smtpmail-send-it
|
|
message-sendmail-f-is-evil t
|
|
message-sendmail-extra-arguments '("--read-envelope-from")
|
|
message-send-mail-function #'message-send-mail-with-sendmail
|
|
message-kill-buffer-on-exit t
|
|
mail-user-agent 'mu4e-user-agent
|
|
read-mail-command 'mu4e
|
|
mu4e-maildir "~/Mail"
|
|
mu4e-attachment-dir "~/Downloads"
|
|
mu4e-get-mail-command "mbsync -a"
|
|
mu4e-update-interval (* 5 60) ; Every 5 minutes
|
|
mu4e-sent-messages-behavior 'sent
|
|
mu4e-change-filenames-when-moving t
|
|
mu4e-context-policy 'pick-first
|
|
mu4e-headers-fields '((:human-date . 12)
|
|
(:flags . 6)
|
|
(:from-or-to . 25)
|
|
(:subject))
|
|
mu4e-headers-actions '(("org capture message" . mu4e-org-store-and-capture)
|
|
("capture message" . mu4e-action-capture-message)
|
|
("show this thread" . mu4e-action-show-thread))
|
|
mu4e-maildir-shortcuts '((:maildir "/Proton/Inbox/" :key ?p)
|
|
(:maildir "/iCloud/Inbox/" :key ?i)
|
|
(:maildir "/Outlook/Inbox/" :key ?w)))
|
|
|
|
(when (require 'mu4e nil :noerror)
|
|
(keymap-global-set "C-c m m" #'mu4e)
|
|
(keymap-global-set "C-c m u" #'mu4e-update-index)
|
|
(keymap-global-set "C-c m c" #'mu4e-compose-new)
|
|
|
|
(when (require 'mu4e-alert nil :noerror)
|
|
(mu4e-alert-set-default-style 'libnotify)
|
|
(mu4e-alert-enable-notifications)
|
|
(mu4e-alert-enable-mode-line-display))
|
|
|
|
(setq mu4e-contexts (list
|
|
(make-mu4e-context
|
|
:name "Xenia"
|
|
:vars '((user-mail-address . "evie@xenia.me.uk")
|
|
(mu4e-sent-folder . "/Proton/Sent")
|
|
(mu4e-drafts-folder . "/Proton/Drafts")
|
|
(mu4e-trash-folder . "/Proton/Trash")
|
|
(mu4e-refile-folder . "/Proton/Archive")))
|
|
(make-mu4e-context
|
|
:name "Proton"
|
|
:match-func (lambda (msg) (when msg (string-prefix-p "/Proton" (mu4e-message-field msg :maildir))))
|
|
:vars '((user-mail-address . "e.litherlandsmith@proton.me")
|
|
(mu4e-sent-folder . "/Proton/Sent")
|
|
(mu4e-drafts-folder . "/Proton/Drafts")
|
|
(mu4e-trash-folder . "/Proton/Trash")
|
|
(mu4e-refile-folder . "/Proton/Archive")))
|
|
(make-mu4e-context
|
|
:name "iCloud"
|
|
:match-func (lambda (msg) (when msg (string-prefix-p "/iCloud" (mu4e-message-field msg :maildir))))
|
|
:vars '((user-mail-address . "e.litherlandsmith@icloud.com")
|
|
(mu4e-sent-folder . "/iCloud/Sent Messages")
|
|
(mu4e-drafts-folder . "/iCloud/Drafts")
|
|
(mu4e-trash-folder . "/iCloud/Deleted Messages")
|
|
(mu4e-refile-folder . "/iCloud/Archive")))
|
|
(make-mu4e-context
|
|
:name "Work"
|
|
:match-func (lambda (msg) (when msg (string-prefix-p "/Outlook" (mu4e-message-field msg :maildir))))
|
|
:vars '((user-mail-address . "evie.litherland-smith@ukaea.uk")
|
|
(mu4e-sent-folder . "/Outlook/Sent")
|
|
(mu4e-drafts-folder . "/Outlook/Drafts")
|
|
(mu4e-trash-folder . "/Outlook/Trash")
|
|
(mu4e-refile-folder . "/Outlook/Archive"))))))
|
|
|
|
(provide 'custom-email-config)
|