Hello,
I am trying to setup email client in emacs.
I decided to use "Wanderlust" to use with Gmail.
below is my config for "Wanderlust" and the .folder file
I have the following problem:
for some reason notifications for new arriving emails are
not working. When new mail arrives, I want to see a message
saying that new mail arrived and also I want that the
summary of emails in the summary buffer to be updated.
Notification for new emails depends on the following 3 lines
(setq wl-biff-check-folder-list '("%INBOX"))
(setq wl-biff-check-interval 60)
(add-hook 'wl-biff-notify-hook 'my-mail-notify)
but for some reason this does not work.
I use the latest version of "Wanderlust" 2.14.0(Africa)
;;==============================================================
;;==============================================================
;;==============================================================
;;==============================================================
(require 'wl)
(autoload 'wl "wl" "Wanderlust" t)
(autoload 'wl-other-frame "wl" "Wanderlust on new frame." t)
(autoload 'wl-draft "wl-draft" "Write draft with Wanderlust." t)
(autoload 'wl-user-agent-compose "wl-draft" "Compose with Wanderlust." t)
(setq mime-edit-split-message nil)
;; In order to handle text/html part with emacs-w3m
;; see http://emacs-w3m.namazu.org/.
(require 'mime-w3m)
(setq wl-from "John Dough <john.do...@gmail.com>")
(setq elmo-imap4-default-user "john.dough"
wl-demo-display-logo nil
wl-folder-desktop-name "GMAIL"
wl-stay-folder-window t
wl-folder-window-width 25
wl-folder-use-frame nil
my-maildir-path "~/Mail"
wl-temporary-file-directory (concat my-maildir-path "/tmp")
elmo-localdir-folder-path my-maildir-path
elmo-maildir-folder-path my-maildir-path
elmo-search-namazu-default-index-path my-maildir-path
elmo-archive-folder-path my-maildir-path
elmo-imap4-default-server "imap.gmail.com"
elmo-imap4-default-port 993
elmo-imap4-default-authenticate-type 'clear
elmo-imap4-default-stream-type 'ssl
elmo-imap4-use-modified-utf7 t
wl-message-id-domain "john.do...@gmail.com"
wl-from "John Dough <john.do...@gmail.com>"
wl-smtp-posting-server "smtp.gmail.com"
wl-smtp-connection-type 'starttls
wl-smtp-posting-port 587
wl-smtp-authenticate-type "plain"
wl-smtp-posting-user "john.dough"
wl-local-domain "gmail.com"
elmo-pop3-debug t
ssl-certificate-verification-policy 1
wl-thread-indent-level 4
wl-thread-have-younger-brother-str "+"
wl-thread-youngest-child-str "+"
wl-thread-vertical-str "|"
wl-thread-horizontal-str "-"
wl-thread-space-str " "
wl-summary-width nil
wl-auto-select-first t
wl-summary-line-format "%T%P %W %D-%M-%Y %t%[%c %f% %] %s"
wl-message-buffer-prefetch-folder-type-list nil
mime-transfer-level 8
mime-edit-split-message nil
mime-edit-message-max-length 32768
mime-header-accept-quoted-encoded-words t
mime-browse-url-function 'browse-url-conkeror
pgg-passphrase-cache-expiry 300
pgg-decrypt-automatically t
wl-message-ignored-field-list '("^.*")
wl-message-visible-field-list '("^From:" "^To:" "^Cc:"
"^Date:" "^Subject:")
wl-message-sort-field-list wl-message-visible-field-list
wl-summary-default-sort-spec 'date
wl-message-window-size '(1 . 3)
wl-draft-preview-attributes-buffer-lines 7
wl-draft-config-alist
'(
((string-match "john.dough" wl-draft-parent-folder)
(wl-message-id-domain . "john.do...@gmail.com")
(wl-from . "John Dough <john.do...@gmail.com>")
("From" . "john.do...@gmail.com")
;; ("Fcc" . "%Sent:john.do...@imap.gmail.com:993")
(wl-smtp-posting-server . "smtp.gmail.com")
(wl-smtp-connection-type . 'starttls)
(wl-smtp-posting-port . 587)
(wl-smtp-authenticate-type . "plain")
(wl-smtp-posting-user . "john.dough")
(wl-local-domain . "gmail.com")
)
)
)
(autoload 'wl-user-agent-compose "wl-draft" nil t)
(if (boundp 'mail-user-agent)
(setq mail-user-agent 'wl-user-agent))
(if (fboundp 'define-mail-user-agent)
(define-mail-user-agent
'wl-user-agent
'wl-user-agent-compose
'wl-draft-send
'wl-draft-kill
'mail-send-hook))
;; set up folders
(setq wl-default-folder "%INBOX")
(setq wl-batch-prefetch-folder-list "%INBOX")
(setq wl-auto-check-folder-name "%INBOX")
(setq wl-default-spec "%")
(setq wl-draft-folder "%[Gmail]/Drafts") ; Gmail IMAP
(setq wl-trash-folder "%[Gmail]/Trash")
(setq wl-folder-check-async t)
;;;; Biff
(setq wl-biff-check-folder-list '("%INBOX"))
(setq wl-biff-check-interval 60)
(defun popup (title msg &optional icon sound)
"Show a popup if we're on X, or echo it otherwise;
TITLE is the title of the message, MSG is the context.
Optionally, you can provide an ICON and a sound"
(interactive)
(when sound (shell-command
(concat "mplayer -really-quiet " sound " 2> /dev/null")))
(if (eq window-system 'x)
(shell-command (concat "notify-send "
(if icon (concat "-i " icon) "")
" '" title "' '" msg "'"))
;; text only version
(message (concat title ": " msg))))
(defun my-mail-notify ()
"Notify through that new mail has arrived."
(popup "Attention! New Mail." "You have new mail!")
(wl-summsry-sync-update))
(add-hook 'wl-biff-notify-hook 'my-mail-notify)
;(wl-biff-start)
(defalias 'gmail 'wl)
;;==============================================================
;;==============================================================
;;==============================================================
;;==============================================================
Also my .folders file is as follows
%INBOX ".INBOX "
%[Gmail]/Important "~Important "
%[Gmail]/Starred "~Starred "
%[Gmail]/Drafts "~Drafts "
%[Gmail]/All Mail "~All Mail "
%[Gmail]/Sent Mail "~Sent Mail "
%[Gmail]/Trash "~Trash "
%[Gmail]/Spam "~Spam "