-
Notifications
You must be signed in to change notification settings - Fork 3
/
.gnus.el
92 lines (77 loc) · 3.03 KB
/
.gnus.el
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
;;; Personal settings
(setq user-mail-address "[email protected]"
mail-host-address "redhat.com"
user-full-name "Jim Crossley"
my-news-server "news.gmane.org"
my-imap-server "mail.corp.redhat.com"
my-smtp-server "smtp.corp.redhat.com"
)
;;; Splitting rules
(setq nnmail-split-methods
'(
("clojure" "^\\(To\\|Cc\\):.*clojure")
("clojure" "^\\(To\\|Cc\\):.*datomic")
("clojure" "^\\(To\\|Cc\\):.*noir")
("aquamacs" "^\\(To\\|Cc\\):.*macosx-emacs")
("torquebox" "^\\(To\\|Cc\\):.*torquebox")
("immutant" "^\\(To\\|Cc\\):.*immutant")
("android" "^\\(To\\|Cc\\):.*android")
("jboss" "^\\(To\\|Cc\\):.*wildfly-dev")))
;;; Primary news server
(setq gnus-select-method `(nntp ,my-news-server))
;;; Secondary (email)
(setq gnus-secondary-select-methods
`(
(nnimap "redhat"
(nnimap-address ,my-imap-server)
(nnimap-stream ssl)
(nnimap-inbox "INBOX")
(nnimap-split-methods default))
(nnml "local")))
;;; Gmail
(add-to-list 'gnus-secondary-select-methods
'(nnimap "gmail"
(nnimap-address "imap.gmail.com")
(nnimap-server-port 993)
(nnimap-stream ssl)
(nnimap-inbox "INBOX")
(nnimap-split-methods default)))
;;; Outbound email
(setq send-mail-function 'smtpmail-send-it)
(setq message-send-mail-function 'smtpmail-send-it)
(setq smtpmail-smtp-server my-smtp-server)
;;; Reduce prompting
(setq gnus-interactive-catchup nil)
(setq gnus-interactive-exit nil)
;;; Save sent mail
(setq gnus-message-archive-group "nnimap+redhat:Sent")
;;; Only display groups with unread articles
(setq gnus-list-groups-with-ticked-articles nil)
;;; Delete read messages automatically after 14 days
(setq gnus-total-expirable-newsgroups ".*")
(setq nnmail-expiry-wait 14)
;;; Prevent gnus from putting this in my custom-file
(setq canlock-password jc/canlock-password)
;;; Look up email addresses in LDAP
(eval-after-load "message"
'(define-key message-mode-map (kbd "TAB") 'eudc-expand-inline))
(setq eudc-ldap-attributes-translation-alist '((lastname . sn)
(firstname . givenname)
(email . mail)
(phone . telephonenumber)
(nickname . rhatknownas)))
(setq eudc-inline-query-format '((nickname) (firstname) (lastname) (firstname lastname)))
(setq eudc-inline-expansion-format '("%s <%s>" cn email))
;;; Posting styles
(setq gnus-posting-styles
'((".*"
(name "Jim Crossley"))
((header "To" ".*googlegroups.*")
(From "Jim Crossley <[email protected]>"))))
;;; Use one of these as my From address when replying
(setq message-alternative-emails
;;; Check mail backends automatically
(gnus-demon-add-scanmail)
;;; Use adaptive scoring
(setq gnus-use-adaptive-scoring t)