procmail
[Top] [All Lists]

Re: procmail & emacs VM

1996-03-11 18:54:56
"dw" == dwalker  <dwalker(_at_)eskimo(_dot_)com> writes:

dw> I want to use procmail with XEmacs VM. Does anyone have experience
dw> with this combination they'd care to relate?

I use VM with procmail and it's very straightforward, as long as you
use multiple spool files. The thing to do (to avoid confusing buffers
and weird emacs locking) is to have procmail save all mail to folders
IN ALL CAPS. Then you have VM use those as spool files and move them
into new folders (from my ~/.vm):

;; Since I use procmail to filter my mail, I like to shove my incoming
;; mail to folders. Due to Emacs (and hence VM) locking, it's not wise
;; to view the incoming spool file, so I make procmail dump mail to
;; folders IN ALL CAPS. Then I have VM make spool files from each one
;; of those, except they'll be in all lower case.
 
(setq vm-spool-files
      (append
       (list
        (list vm-primary-inbox
              "/var/mail/cdh"
              "/var/mail/cdh.crash"))
       ;; Mailing list inboxes
       ;; I arrange that all my procmail maildrops are in ~/Mail/[A-Z]*
       (mapcar '(lambda (s)
                  "make the appropriate entry for vm-spool-files"
                  (list
                   (concat vm-folder-directory s)
                   (concat vm-folder-directory (upcase s))
                   (concat vm-folder-directory s ".crash")))
               ;; So I create a vm-spool-files entry for each mail drop
               (mapcar 'downcase
                       (directory-files vm-folder-directory nil "^[A-Z].+")))))

Of course, change the "/var/mail/cdh" to wherever your real spool file
is. Then just have procmail save in those folders, as in:

:0:
* ^TOprocmail
PROC

You then visit ("v" in VM) the folder "proc". VM will
auto-magically grab the mail from the "spool" file PROC and put it in
the "proc" folder. 

Chris

--
Chris D. Halverson                |  Network Engineer
Minnesota Regional Network        |  Voice: (612) 342-2838
511 11th Avenue South, Box 212    |  Email: cdh(_at_)MR(_dot_)Net
Minneapolis, MN  55415            |  WWW:   http://www.MR.Net/~cdh/
    PGP signed/encrypted mail accepted, finger for PGP public key

<Prev in Thread] Current Thread [Next in Thread>