1 ;;; dot.wl -- sample setting file for Wanderlust -*- emacs-lisp -*-
5 ;; Disable inline display of HTML part.
6 ;; Put before (require 'mime-setup)
7 (setq mime-setup-enable-inline-html nil)
9 ;; Don't split large message.
10 (setq mime-edit-split-message nil)
12 ;; If lines of message are larger than this value, treat it as `large'.
13 ;(setq mime-edit-message-default-max-lines 1000)
16 ;; [[ Requirement Setting ]]
18 ;; Following must be included in ~/.emacs
21 (autoload 'wl "wl" "Wanderlust" t)
22 (autoload 'wl-draft "wl-draft" "Write draft with Wanderlust." t)
25 ;; Icon directory (XEmacs and Emacs21 only)
26 ;; (No need if installed as XEmacs package.)
27 ;(setq wl-icon-dir "/usr/local/lib/emacs/etc")
30 ;;; [[ Private Setting ]]
33 ;(setq wl-from "Your Name <e-mail@example.com>")
35 ;; User's mail addresses.
36 (setq wl-user-mail-address-list
37 (list (wl-address-header-extract-address wl-from)
38 ;; "e-mail2@example.com"
39 ;; "e-mail3@example.net" ...
42 ;; Subscribed mailing list.
43 (setq wl-subscribed-mailing-list
46 "emacs-mime-ja@m17n.org"
47 ;; "ml@example.com" ...
50 ;; If (system-name) does not return FQDN,
51 ;; set following as a local domain name without hostname.
52 ;; ((system-name) "." wl-local-domain is used as domain part of Message-ID
53 ;; and an argument of HELO in SMTP.
54 ;(setq wl-local-domain "example.com")
56 ;; Specific domain part for message-id.
57 ;(setq wl-message-id-domain "hostname.example.com")
60 ;;; [[ Server Setting ]]
62 ;; Default IMAP4 server
63 (setq elmo-imap4-default-server "localhost")
65 (setq elmo-pop3-default-server "localhost")
67 (setq wl-smtp-posting-server "localhost")
68 ;; Default NNTP server
69 (setq elmo-nntp-default-server "localhost")
70 ;; NNTP server name for posting
71 (setq wl-nntp-posting-server elmo-nntp-default-server)
73 ;; IMAP authenticate type setting
74 (setq elmo-imap4-default-authenticate-type 'clear) ; raw
75 ;(setq elmo-imap4-default-authenticate-type 'cram-md5) ; CRAM-MD5
78 ;(setq wl-draft-send-mail-function 'wl-draft-send-mail-with-pop-before-smtp)
81 ;;; [[ Basic Setting ]]
83 ;; Default folder for `wl-summary-goto-folder'.
84 ;(setq wl-default-folder "+inbox")
86 ;; Default string for folder name completion.
87 ;(setq wl-default-spec "+")
90 ;(setq wl-fcc "+outbox")
92 ;; Confirm before exitting Wanderlust.
93 (setq wl-interactive-exit t)
95 ;; Confirm before sending message.
96 (setq wl-interactive-send t)
98 ;; Create opened thread.
99 ;(setq wl-thread-insert-opened t)
101 ;; Keep folder window beside summary. (3 pane)
102 ;(setq wl-stay-folder-window t)
104 ;; Open new frame for draft buffer.
105 ;(setq wl-draft-use-frame t)
107 ;; Divide thread by change of subject.
108 ;(setq wl-summary-divide-thread-when-subject-changed t)
111 ;(setq wl-thread-indent-level 2)
112 ;(setq wl-thread-have-younger-brother-str "+"
113 ; wl-thread-youngest-child-str "+"
114 ; wl-thread-vertical-str "|"
115 ; wl-thread-horizontal-str "-"
116 ; wl-thread-space-str " ")
118 ;; display first message automatically.
119 ;(setq wl-auto-select-first t)
121 ;; goto next folder when exit from summary.
122 ;(setq wl-auto-select-next t)
124 ;; skip folder if there is no unread message.
125 ;(setq wl-auto-select-next 'skip-no-unread)
127 ;; jump to unread message in 'N' or 'P'.
128 ;(setq wl-summary-move-order 'unread)
130 ;; notify mail arrival
131 ;(setq wl-biff-check-folder-list '("%inbox"))
132 ;(setq wl-biff-notify-hook '(beep))
137 ;; (messages in localdir, localnews, maildir are not cached.)
138 ;(setq elmo-archive-use-cache nil)
139 ;(setq elmo-nntp-use-cache t)
140 ;(setq elmo-imap4-use-cache t)
141 ;(setq elmo-pop3-use-cache t)
143 ;; Enable disconnected operation in IMAP folder.
144 ;(setq elmo-enable-disconnected-operation t)
146 ;; Store draft message in queue folder if message is sent in unplugged status.
147 (setq wl-draft-enable-queuing t)
148 ;; when plug status is changed from unplugged to plugged,
149 ;; queued message is flushed automatically.
150 (setq wl-auto-flush-queue t)
152 ;; offline at startup.
153 ;(setq wl-plugged nil)
154 ;; change plug status by server or port at startup.
155 ;(add-hook 'wl-make-plugged-hook
157 ; ;; Add or Change plug status for SERVER and PORT.
158 ; (elmo-set-plugged plugged(t/nil) server port)
159 ; ;; When omit port, SEVERS all port was changes.
160 ; ;; (Can't add plug status without PORT)
161 ; (elmo-set-plugged plugged(t/nil) server)
165 ;;; [[ Special Setting ]]
167 ;; open unread group folder after checking.
168 ;(add-hook 'wl-folder-check-entity-hook
170 ; (wl-folder-open-unread-folder entity)
173 ;; Change summary display function.
175 ;; get extra field values as overview information (only localdir folder).
176 (setq elmo-msgdb-extra-fields
178 "list-id" "x-ml-name" "mailing-list"
179 "x-mail-count" "x-ml-count" "x-sequence"))
181 ;; ML message displays ML name and ML sequence number in subject.
182 (setq wl-summary-subject-function 'my-wl-summary-subject-func-ml)
183 (defun my-wl-summary-subject-func-ml (subject-string)
184 (let ((folder wl-summary-buffer-folder-name)
185 (subj subject-string) (sequence) (ml-name) (ml-count))
186 (setq sequence (elmo-msgdb-overview-entity-get-extra-field
188 ml-name (or (elmo-msgdb-overview-entity-get-extra-field
191 (car (split-string sequence " "))))
192 ml-count (or (elmo-msgdb-overview-entity-get-extra-field
193 entity "x-mail-count")
194 (elmo-msgdb-overview-entity-get-extra-field
197 (cadr (split-string sequence " ")))))
199 "^\\s(\\(\\S)+\\)[ :]\\([0-9]+\\)\\s)[ \t]*"
202 (setq subj (substring subject-string (match-end 0)))
203 (if (not ml-name) (setq ml-name (match-string 1 subject-string)))
204 (if (not ml-count) (setq ml-count (match-string 2 subject-string)))))
205 (if (and ml-name ml-count)
206 (if (string= folder wl-default-folder)
207 (format "(%s %05d) %s"
208 (car (split-string ml-name " "))
209 (string-to-int ml-count)
212 (string-to-int ml-count) subj))
215 ;; imput asynchronously.
216 ;; (utils/im-wl.el is needed to be installed.
217 ;; Don't forget setting ~/.im/Config (Smtpservers).
218 ;; note that wl-draft-enable-queuing is not valid.)
219 ;(autoload 'wl-draft-send-with-imput-async "im-wl")
220 ;(setq wl-draft-send-function 'wl-draft-send-with-imput-async)
223 ;; non-verbose User-Agent: field
224 ;(setq wl-generate-mailer-string-function
227 ; (concat "User-Agent: "
228 ; (wl-generate-user-agent-string-1 nil)))))
234 (setq wl-template-alist
237 ("Organization" . "~/.wl sample")
238 (body . "Hello, this is XXX \n")) ;; body
240 ("To" . "boss@example.com")
241 ("Subject" . "Report")
242 (top . "Sir, here is my report\n") ;; insert in top.
243 ;; (bottom-file . "~/work/report.txt") ;; insert file in bottom
246 ;; Change headers in draft sending time.
247 (setq wl-draft-config-alist
248 '((reply ;; see reply buffer
249 "^To: .*\\(test-notsend-wl@lists.airs.net\\)"
250 (template . "default")) ;; template
251 ("^To: .*\\(test-notsend-wl@lists.airs.net\\)"
252 wl-ml-draft-config-function ;; function
253 ("From" . wl-from) ;; variable
254 ("Organization" . "~/.wl sample")) ;; string
255 ("^Newsgroups: test.*"
256 ("Organization" . "organization for nntp."))
259 ;; Change headers in draft preparation time.
260 ;(add-hook 'wl-mail-setup-hook
262 ; (unless wl-draft-reedit; ; don't apply when reedit.
263 ; (wl-draft-config-exec wl-draft-config-alist))))
267 ;; header value setting for mail reply.
269 ;; Wide window for draft buffer.
270 ;(setq wl-draft-reply-buffer-style 'full)
272 ;; Remove fullname in reply message header.
273 ;(setq wl-draft-reply-use-address-with-full-name nil)
275 ;; "a" (without-argument) reply to author (Reply-To or From).
276 ;; if 'X-ML-Name' and 'Reply-To' exists, reply to 'Reply-To'.
277 (setq wl-draft-reply-without-argument-list
278 '((("X-ML-Name" "Reply-To") . (("Reply-To") nil nil))
279 ("X-ML-Name" . (("To" "Cc") nil nil))
280 ("Followup-To" . (nil nil ("Followup-To")))
281 ("Newsgroups" . (nil nil ("Newsgroups")))
282 ("Reply-To" . (("Reply-To") nil nil))
283 ("Mail-Reply-To" . (("Mail-Reply-To") nil nil))
284 ("From" . (("From") nil nil))))
286 ;; "C-u a" (with-argument) reply to all.
287 (setq wl-draft-reply-with-argument-list
288 '(("Followup-To" . (("From") nil ("Followup-To")))
289 ("Newsgroups" . (("From") nil ("Newsgroups")))
290 ("Mail-Followup-To" . (("Mail-Followup-To") nil ("Newsgroups")))
291 ("From" . (("From") ("To" "Cc") ("Newsgroups")))))
294 ;;; [[ Message Display Settings ]]
296 ;; Hidden header field in message buffer.
297 (setq wl-message-ignored-field-list
298 '(".*Received:" ".*Path:" ".*Id:" "^References:"
299 "^Replied:" "^Errors-To:"
300 "^Lines:" "^Sender:" ".*Host:" "^Xref:"
301 "^Content-Type:" "^Precedence:"
302 "^Status:" "^X-VM-.*:"))
304 ;; Displayed header field in message buffer.
305 ;; This value precedes `wl-message-ignored-field-list'
306 (setq wl-message-visible-field-list '("^Message-Id:"))
308 ;; X-Face (requires x-face or bitmap-mule)
310 (cond ((and (featurep 'xemacs) ; for XEmacs
311 (module-installed-p 'x-face))
312 (autoload 'x-face-xmas-wl-display-x-face "x-face")
313 (setq wl-highlight-x-face-function 'x-face-xmas-wl-display-x-face))
314 ;; for Mule (GNU Emacs)
315 ((module-installed-p 'x-face-mule)
316 ;; for x-face-mule distributed with bitmap-mule 8.0 or later
317 (autoload 'x-face-decode-message-header "x-face-mule")
318 (setq wl-highlight-x-face-function 'x-face-decode-message-header))
322 ;; "all.SCORE" file is used regardless of wl-score-folder-alist.
323 ;(setq wl-score-folder-alist
330 ;; rule for auto refile.
331 ;(setq wl-refile-rule-alist
334 ; ("^Wanderlust" . "+wl")
335 ; ("^Elisp" . "+elisp"))
337 ; ("teranisi@isl.ntt.co.jp" . "+teranisi"))))
339 ;; Marks to skip auto-refile (default is "N" "U" "!").
340 ;; nil means all message is auto-refiled.
341 ;(setq wl-summary-auto-refile-skip-marks nil)