[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Wanderlust beginner part 2



At Tue, 20 Apr 2010 15:35:40 +0100, Simon Brown <simon@cliffestones.demon.co.uk> wrote:
Subject: Wanderlust beginner part 2
> 
> My wanderlust setup is getting there thanks to your help but there are
> a few things I've yet to work out. The most important is how do you
> disable folder scanning at applcation start? It's taking far too long
> and I don't need it to be done.

If you're not running the CVS version, try that -- it's orders of
magnitude faster at scanning IMAP folders.  I see WL scan over 240
folders in less than 5 seconds with emacs running on the same
(2xHT-core) machine as my Cyrus IMAP server.  That seems very fast to
me, and is more than fast enough at start-up time, or for whenever I
occasionally hit 's' on the "inbox" folder.

(older versions of WL were VERY slow in comparison)


> Secondly is it possible to represent IMAP folders as a hierachy? I
> have folders for archiving things on the IMAP server (%/) which I'd
> like to be able to open and close as and when I want to see the
> contents. Like what happens with the threading code. At the moment I'm
> just getting a flat list.

WL is very far less than ideal at handling folder hierarchies than it
probably could be, but with some care, and with learning to use <M-RET>
to re-scan sub-folders for new folders, and with some occasional manual
"editing" of the Folder buffer to manage folder order (usually only
necessary if some other IMAP client creates or deletes folders), it is
workable.  (If there's one part of WL that needs a major overhaul, this
is it!  I would love it if it would work like, for example, Apple Mail
does, but _not_ like Thunderbird or other subscription-based MUAs do.
Scanning should notice changes in folder structure and deal with them.)

In my ~/.folders file:

	example.com IMAP folders{
		%inbox:woods@mail.example.com:993!/
	}

In my ~/.wl:

(I'm not 100% sure this is everything needed, though it should be
close.  I can make my entire ~/.wl file available if you like.)

;; try to create sub-folders for every level in IMAP using a recursive RE
;;
;; this doesn't properly take into account the actual hierarchy separator
;; specified by the IMAP server (it just allows either, and would no doubt be
;; royally messed up if the char that's not the true separator appears in a
;; folder name).
;;
;; XXX this recursive RE doesn't exactly work right.  It has the desired
;; effect, but only _after_ WL has learned the underlying structure, which it
;; seems can only currently be done by commenting out the recursive RE and
;; leaving just the non-recursive non-hierarchical match for IMAP folders
;; (i.e. the line below marked "XXX is this necessary?") while re-opening
;; all folders with "ESC RET", then putting it back and doing it again.
;;
;; Note: if you change the hierarchy and want to rebuild the tree do:
;;
;;	rm -rf ~/.elmo/folder
;;
(setq wl-folder-hierarchy-access-folders
      '(
	"^%\\([^/.]+[/.]\\)*[^/.]+\\(:\\|@\\|$\\)" ; for IMAP (recursive)
	"^%[^/.]+\\(:\\|@\\|$\\)"	; for IMAP (XXX is this necessary?)
	"^-[^.]*\\(:\\|@\\|$\\)"	; for NNTP
	"^@$"				; for Shimbun (?)
	"^'$"				; for internal (?)
	))

;; also do this to avoid having groups show up before the mailbox with
;; the same name as the group
;;
;; I wish wl-folder-update-recursive-current-entity would start with
;; things in the same order as wl-fldmgr-sort does, though I suppose I
;; could wrap the former with some advice to call the latter after it is
;; done to achieve the same effect.
;;
(setq wl-fldmgr-sort-group-first nil)


> Thirdly, is there an easy way to add signatures. The methods I've
> found so far are ridiculously complicated.

This is what I do in my ~/.wl for automatic signing:

(setq wl-draft-config-alist
      '(
	; defaults for everything
	((or t)
	 (pgp-sign . t)
	 mime-edit-insert-signature)))

(setq signature-insert-at-eof t)
(setq signature-file-alist
      '((("From" . "@example1\\.com") . "~/.signature-example1.com")
	(("From" . "@example2\\.com") . "~/.signature-example2.com")
	(("From" . ".") . "~/.signature")))

-- 
						Greg A. Woods
						Planix, Inc.

<woods@planix.com>       +1 416 218 0099        http://www.planix.com/