summaryrefslogtreecommitdiffstats
path: root/Mu4e.org
diff options
context:
space:
mode:
authorjdlugosz963 <jdlugosz963@gmail.com>2022-10-01 16:25:46 +0200
committerjdlugosz963 <jdlugosz963@gmail.com>2022-10-01 16:25:46 +0200
commited2706555050dfc6317899ba4b8d849c894954f0 (patch)
treebaa393e167f8b16adc2537d766575a23e889cfaf /Mu4e.org
parent7576787242f9a7834c6acd29657150d03f51f0d9 (diff)
downloaddotfiles-ed2706555050dfc6317899ba4b8d849c894954f0.tar.gz
dotfiles-ed2706555050dfc6317899ba4b8d849c894954f0.zip
Rename Mail.org to Mu4e.org
Diffstat (limited to 'Mu4e.org')
-rw-r--r--Mu4e.org124
1 files changed, 124 insertions, 0 deletions
diff --git a/Mu4e.org b/Mu4e.org
new file mode 100644
index 0000000..21ad1b7
--- /dev/null
+++ b/Mu4e.org
@@ -0,0 +1,124 @@
1#+TITLE: MU4E Configuration
2#+PROPERTY: header-args:emacs-lisp :tangle .config/emacs/jd/jd-mu4e.el
3
4* jd-mu4e.el
5#+begin_src emacs-lisp
6
7 (add-to-list 'load-path "/usr/share/emacs/site-lisp/mu4e")
8
9
10 (use-package org-msg
11 :ensure t)
12
13 (use-package mu4e
14 :defer 20
15 :ensure nil
16 :config
17 (require 'org-mu4e)
18
19 (setq mu4e-update-interval (* 10 60))
20 (setq mu4e-get-mail-command "mbsync -a")
21 (setq mu4e-maildir "~/Mail")
22
23 (setq mu4e-completing-read-function #'ivy-completing-read)
24
25 (setq mu4e-change-filenames-when-moving t)
26
27 (setq mu4e-contexts
28 `(,(make-mu4e-context
29 :name "Abaks"
30 :match-func (lambda (msg) (when msg
31 (string-prefix-p "/abaks" (mu4e-message-field msg :maildir))))
32 :vars '(
33 (user-full-name . "Jakub Dlugosz")
34 (user-mail-address . "jakub@abaks.pl")
35 (mu4e-sent-folder . "/abaks/Sent Items")
36 (mu4e-trash-folder . "/abaks/Trash")
37 (mu4e-drafts-folder . "/abaks/Drafts")
38 (mu4e-refile-folder . "/abaks/Archive")
39 (mu4e-sent-messages-behavior . sent)
40 ))
41 ,(make-mu4e-context
42 :name "Gmail"
43 :match-func (lambda (msg) (when msg
44 (string-prefix-p "/gmail" (mu4e-message-field msg :maildir))))
45 :vars '(
46 (user-full-name . "Jakub Dlugosz")
47 (user-mail-address . "jdlugosz963@gmail.pl")
48 (mu4e-sent-folder . "/gmail/\[Gmail\]/Wys\&AUI-ane")
49 (mu4e-trash-folder . "/gmail/\[Gmail\]/Kosz")
50 (mu4e-drafts-folder . "/gmail/\[Gmail\]/Wersje\ robocze")
51 (mu4e-refile-folder . "/gmail/Archive")
52 (mu4e-sent-messages-behavior . sent)
53 ))))
54
55 (setq mail-user-agent 'mu4e-user-agent
56 message-send-mail-function 'smtpmail-send-it
57 smtpmail-smtp-server "smtp.abaks.pl"
58 smtpmail-local-domain "pl"
59 smtpmail-smtp-service 465
60 smtpmail-stream-type 'ssl)
61
62 (mu4e t))
63
64 (jd/leader-key-def
65 "m" '(:ignore t :which-key "mail")
66 "mm" 'mu4e
67 "mc" 'mu4e-compose-new)
68
69
70 (provide 'jd-mu4e)
71
72#+end_src
73
74* mbsyncrc
75
76#+begin_src conf :tangle .mbsyncrc
77IMAPStore abaks-remote
78Host imap.abaks.pl
79Port 143
80SSLType None
81AuthMechs LOGIN
82User jakub@abaks.pl
83PassCmd "pass email/jakub@abaks.pl"
84CertificateFile /etc/ssl/certs/ca-certificates.crt
85
86MaildirStore abaks-local
87Path ~/Mail/abaks/
88Inbox ~/Mail/abaks/INBOX
89Subfolders Verbatim
90
91Channel abaks
92Far :abaks-remote:
93Near :abaks-local:
94Patterns INBOX * !Sync*
95Expunge None
96CopyArrivalDate yes
97Sync All
98Create Near
99SyncState *
100
101IMAPStore gmail-remote
102Host imap.gmail.com
103Port 993
104SSLType IMAPS
105AuthMechs LOGIN
106User jdlugosz963@gmail.com
107PassCmd "pass email/jdlugosz963@gmail.com"
108CertificateFile /etc/ssl/certs/ca-certificates.crt
109
110MaildirStore gmail-local
111Path ~/Mail/gmail/
112Inbox ~/Mail/gmail/INBOX
113Subfolders Verbatim
114
115Channel gmail
116Far :gmail-remote:
117Near :gmail-local:
118Patterns INBOX * !Sync*
119Expunge None
120CopyArrivalDate yes
121Sync All
122Create Near
123SyncState *
124#+end_src