Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: PATCH: completion for MUAs



On Apr 13,  7:31pm, Oliver Kiddle wrote:
} Subject: PATCH: completion for MUAs
}
} The one thing which hasn't been done for any MUA is to parse the
} addressbook/alias list and use it for generating the e-mail addresses.
} 
} Does anyone have suggestions for getting at or parsing the addressbooks
} of different MUAs (apart from MH which is easy)?

There are quite a variety of addressbook formats, ranging from nothing
more than a batch of commands or assignments in the MUA's init files
through Pine's tab-delimited records to networked LDAP lookup.  Rather
than try to provide a function that parses any significant subset of
these, I suggest working out some kind of a plugin model -- paste up a
function name using $service or the like, and call it if it exists.

Then there's also completion of user names @ the local machine, and
maybe even /etc{/mail,}/aliases names or the equivalent for other MTAs.

} Some MUAs are happy with addresses in forms like 'Name <user@host>' and
} 'user@host (Name)'. Any thoughts on how to deal with these (such as
} whether it would be useful to expand to these) and other complications
} such as distribution lists would be helpful.

Some MUAs also are happy with comma-separated lists of addresses in one
or more command-line arguments while others make each argument an address
and don't attempt to parse it further (which can lead to strange problems
later when calling the MTA or having an SMTP conversation).

I'd advise completing only the user@host part, unless it's too difficult
to pick it out of the addressbook entry (but that'd be up to the plugin
in any case, if you take my advice above).

By "distribution lists" do you mean `@groupname:addr,addr,addr;' syntax,
or are you talking about e.g. completing individual addresses that appear
in the definition of a group or alias in the addressbook, or ...?

-- 
Bart Schaefer                                 Brass Lantern Enterprises
http://www.well.com/user/barts              http://www.brasslantern.com

Zsh: http://www.zsh.org | PHPerl Project: http://phperl.sourceforge.net   



Messages sorted by: Reverse Date, Date, Thread, Author