diff options
author | Case Duckworth | 2021-10-07 18:23:59 -0500 |
---|---|---|
committer | Case Duckworth | 2021-10-07 18:23:59 -0500 |
commit | 88a27cd598b9283ede861cc9281a073837b5c162 (patch) | |
tree | a8f630a20ba10284fadc0e49153cc7c337e4139d | |
parent | Figure out flymake-inhibiting after reading local variables (diff) | |
download | emacs-88a27cd598b9283ede861cc9281a073837b5c162.tar.gz emacs-88a27cd598b9283ede861cc9281a073837b5c162.zip |
Add mu4e contexts
-rw-r--r-- | init.el | 63 |
1 files changed, 50 insertions, 13 deletions
diff --git a/init.el b/init.el index d3b05c8..e424c84 100644 --- a/init.el +++ b/init.el | |||
@@ -690,20 +690,57 @@ specific to most general, they are these: | |||
690 | 690 | ||
691 | (setup mu4e | 691 | (setup mu4e |
692 | (:load-from "/usr/share/emacs/site-lisp/mu4e") | 692 | (:load-from "/usr/share/emacs/site-lisp/mu4e") |
693 | (:option mu4e-change-filenames-when-moving t | 693 | (:autoload (mu4e :interactive t) |
694 | mu4e-update-interval (* 10 60) | 694 | make-mu4e-context) |
695 | (:option message-kill-buffer-on-exit t | ||
696 | message-send-mail-function #'smtpmail-send-it | ||
697 | mu4e-change-filenames-when-moving t | ||
698 | mu4e-contexts | ||
699 | (list | ||
700 | ;; Work | ||
701 | (make-mu4e-context | ||
702 | :name "Work" | ||
703 | :match-func (lambda (msg) | ||
704 | (when msg | ||
705 | (string-prefix-p | ||
706 | work-mail-dir | ||
707 | (mu4e-message-field msg :maildir)))) | ||
708 | :vars `((user-mail-address . ,work-email) | ||
709 | (smtpmail-smtp-server . ,work-smtp-server) | ||
710 | (mu4e-compose-format-flowed . nil) | ||
711 | (mu4e-drafts-folder | ||
712 | . ,(concat work-mail-dir "/[Gmail]/Drafts")) | ||
713 | (mu4e-sent-folder | ||
714 | . ,(concat work-mail-dir "/[Gmail]/Sent Mail")) | ||
715 | (mu4e-refile-dir | ||
716 | . ,(concat work-mail-dir "/[Gmail]/All Mail")) | ||
717 | (mu4e-trash-folder | ||
718 | . ,(concat work-mail-dir "/[Gmail]/Trash")))) | ||
719 | ;; Home | ||
720 | (make-mu4e-context | ||
721 | :name "Home" | ||
722 | :match-func (lambda (msg) | ||
723 | (when msg | ||
724 | (string-prefix-p | ||
725 | home-mail-dir | ||
726 | (mu4e-message-field msg :maildir)))) | ||
727 | :vars `((user-mail-address . ,home-email) | ||
728 | (smtpmail-smtp-server . ,home-smtp-server) | ||
729 | (mu4e-compose-format-flowed . nil) | ||
730 | (mu4e-drafts-folder | ||
731 | . ,(concat home-mail-dir "/Drafts")) | ||
732 | (mu4e-sent-folder | ||
733 | . ,(concat home-mail-dir "/Sent")) | ||
734 | (mu4e-refile-folder | ||
735 | . ,(concat home-mail-dir "/Archive")) | ||
736 | (mu4e-trash-folder | ||
737 | . ,(concat home-mail-dir "/Trash"))))) | ||
695 | mu4e-get-mail-command "mbsync -a" | 738 | mu4e-get-mail-command "mbsync -a" |
696 | mu4e-maildir "~/mail/clickhere") | 739 | mu4e-maildir "~/mail" |
697 | (:option mu4e-drafts-folder "/[Gmail]/Drafts" | 740 | mu4e-update-interval (* 10 60) |
698 | mu4e-sent-folder "/[Gmail]/Sent Mail" | 741 | send-mail-function #'smtpmail-send-it |
699 | mu4e-refile-folder "/[Gmail]/All Mail" | 742 | smtpmail-smtp-service 465 |
700 | mu4e-trash-folder "/[Gmail]/Trash" | 743 | smtpmail-stream-type 'ssl)) |
701 | mu4e-maildir-shortcuts | ||
702 | `((:maildir "/Inbox" :key ?i) | ||
703 | (:maildir ,mu4e-drafts-folder :key ?d) | ||
704 | (:maildir ,mu4e-sent-folder :key ?s) | ||
705 | (:maildir ,mu4e-refile-folder :key ?a) | ||
706 | (:maildir ,mu4e-trash-folder :key ?t)))) | ||
707 | 744 | ||
708 | (setup page | 745 | (setup page |
709 | (:option page-delimiter | 746 | (:option page-delimiter |