Re: hooks into Address DB?
Hal DeVore <haldevore <at> acm.org>
2003-08-09 14:21:38 GMT
>>>>> On Thu, 7 Aug 2003, "bergman" == bergman <at> panix.com wrote:
bergman> Hmmm... Is there a way to call that from outside exmh
bergman> (ie, in a shell script)?
Sure. Using the Tcl "send" command. You can find a few
examples of using the send command in the misc directory.
>>>>> On Thu, 7 Aug 2003, "bergman" == bergman <at> panix.com wrote:
bergman> If not, is the From: address available as a Tcl
bergman> variable while viewing the current message, or do I
bergman> have to parse the message to extract that address
bergman> before it can be unset?
The addr.tcl file contains this code which saves the From
address:
proc Hook_MsgShowAddr {path headervar } {
upvar $headervar header
global addr_db
set addr_db(last_seen) [list $path $header(0=1,hdr,from) $header(0=1,hdr,date)]
if {! $addr_db(enabled)} {
return
}
Addr_Save [MsgParseFrom $header(0=1,hdr,from)] $path \
$header(0=1,hdr,from) $header(0=1,hdr,date)
}
(Continue reading)