nixos/home/emacs/modules/custom-email-config.el
Evie Litherland-Smith 6f04773670 Add doom-modeline, nerd-icons for dired, completion, etc...
Change some keymaps that didn't need to be hydras into regular keymaps

Misc formatting of module files to be a bit easier to read/understand
2023-10-29 07:00:48 +00:00

50 lines
2.2 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)
(when (require 'notmuch nil :noerror)
(keymap-set global-map "C-c m m" #'notmuch)
(keymap-set global-map "C-c m c" #'notmuch-mua-new-mail)
(keymap-set global-map "C-c m s" #'notmuch-search)
(setq mail-user-agent 'notmuch-user-agent
notmuch-search-oldest-first nil
notmuch-show-logo nil
notmuch-hello-thousands-separator ","
notmuch-archive-tags '("+archive" "-inbox")
notmuch-message-headers-visible nil
notmuch-multipart/alternative-discouraged '("text/plain" "multipart/related")
notmuch-show-all-multipart/alternative-parts nil
notmuch-hello-sections '(notmuch-hello-insert-header
notmuch-hello-insert-saved-searches
notmuch-hello-insert-inbox
notmuch-hello-insert-alltags)
notmuch-fcc-dirs '((".*@xenia.me.uk" . "Proton/Sent")
(".*@proton.me" . "Proton/Sent")
(".*@litherlandsmith.slmail.me" . "Proton/Sent")
(".*@icloud.com" . "iCloud/Sent")
(".*@ukaea.uk" . "Outlook/Sent")
(".*@jet.uk" . "Outlook/Sent"))
notmuch-saved-searches '((:name "inbox" :query "tag:inbox" :key "i")
(:name "unread" :query "tag:unread AND tag:inbox" :key "u")
(:name "flagged" :query "tag:flagged" :key "f")
(:name "sent" :query "tag:sent" :key "t")
(:name "drafts" :query "tag:draft" :key "d")
(:name "all mail" :query "*" :key "a"))
notmuch-tagging-keys '(("a" notmuch-archive-tags "Archive")
("u" notmuch-show-mark-read-tags "Mark read")
("f" ("+flagged") "Flag")
("s" ("+spam" "-inbox") "Mark as spam")
("d" ("+deleted" "-inbox" "-unread") "Delete")))
(when (require 'notmuch-indicator nil :noerror)
(setq notmuch-indicator-args '((:terms "tag:unread AND tag:inbox" :label "󰮒 "))
notmuch-indicator-force-refresh-commands '(notmuch-refresh-this-buffer
notmuch-refresh-all-buffers
notmuch-poll-and-refresh-this-buffer))
(notmuch-indicator-mode +1)))
(provide 'custom-email-config)