Wanderlust and EBDB integration

Eric Abrahamsen <[email protected]> Mon, 02 Oct 2017 16:57:47 -0700
Newsgroups gmane.mail.wanderlust.general
Message-ID <87shf1drwk.fsf__19087.563645053$1506988762$gmane$org@ericabrahamsen.net>
Hi all,

I've been working a package called EBDB, which is kind of a port or
rewrite of BBDB, the contact management package. I saw the recent
threads here about BBDB, which prompted me to provide EBDB support for
Wanderlust as well. In terms of its interaction with MUAs, EBDB works
much the same as BBDB (same hooks and whatnot).

Minimal testing indicates it's working fine -- here's what the library
look like now:

https://github.com/girzel/ebdb/blob/master/ebdb-wl.el

The one thing I'm missing is a couple of functions for extracting the
message body and message signature of the message currently being
viewed. This is for the purpose of extracting contact information from
the text: ie, if someone emails you someone else's name and email
address, EBDB should be able to extract that automatically from the
message and create a new contact.

The functions need to start in the summary buffer (`wl-summary-mode'),
and do a save-excursion down to the message itself. One function returns
the body of the message as a string, the other function returns the
signature as a string.

Fifteen minutes with the WL codebase didn't reveal a succinct solution
for this, can anyone point me in the right direction?

Also: EBDB provides completion in mail composition modes, for names and
email addresses. I looked at WL's completion code, and it looks like I
would set `wl-address-init-function' to something that dumped the entire
EBDB into `wl-address-completion-list'. That seems fairly extreme, as it
duplicates potentially a huge amount data. Right now I've provided the
option to override the TAB key to call `ebdb-complete-mail' instead of
WL's own functions, but if there's a more graceful way of integrating
EBDB mail completion, I would love to know about it.

Thanks,
Eric