Forum

 
Current User: Guest Login Register
Please consider registering


Register? | Lost Your Password?

Result of executing a external program?

Add a New Topic Reply to Post
UserPost

4:00 pm
December 8, 2009


doug

Guest

Hi,

Your extension sounds just like what I need!  But It is not clear if the result of running the external program or script can be fed back into Thunderbird to make it do -whatever- to the current message – i.e. the external program is a more advanced filter.  I would like to run e-mails I get through a processor, then send them to the trash or flag them for inspection.  Am I overlooking something, do I need to read the docs, or is this planned for the future?

thanks,

doug

11:30 pm
December 8, 2009


rkent

Admin

posts 140

The ability to use a filter action to run or launch an external program, which are the available custom actions, would be difficult to use as a filter as you need. But there are some other options.

The easiest thing that you could do would be to use the new javascript custom search term. You could define some arbitrary javascript, which will return whether the message matches your criteria or not. Then you can setup a filter action to do whatever you want – trash, flag, etc. Or you could write your own custom search term, following the examples in the extension.

I'm not sure if the message body is going to be available to you though. There's a hook in the custom search term code that will delay the application of the custom search term until after the body is available, just like is done for the new IMAP body filter. But I have not tested it yet, so I don't know if it will actually allow access to the body, particularly because of the async nature of most body processing. But maybe.

If you were quite ambitious, you could write a custom component to override the existing junk mail plugin. That give you full async response possibilities, and is applied quite late in the message processing loop. But that is probably much more involved thatn you are looking at.

Reply to Post

Reply to Topic:
Result of executing a external program?

Guest Name (Required):

Guest Email (Required):

NOTE: New Posts are subject to administrator approval before being displayed

Smileys
Confused Cool Cry Embarassed Frown Kiss Laugh Smile Surprised Wink Yell
Post New Reply

Guest URL (required)

Math Required!
What is the sum of:
12 + 7