[exim] Stop SAVE appending

Góra strony
Delete this message
Reply to this message
Autor: Rob Gunther
Data:  
Dla: Exim Mailing List
Temat: [exim] Stop SAVE appending
I'm trying to have Exim save some messages.

>From a router I call a file, which contains my logic.


if first_delivery then

        if "${if exists{/msg/$message_id}{true}{false}}" is false then


                noerror save /msg/$message_id


        endif


endif


That works, it will save a copy of the message. However, if there are
multiple recipients it will append the message once for every recipient.

I attempted to add the if exists logic, to prevent multiple copies of the
message - I only need it once.

I'm guessing that if exists uses a cached result? The first time it does
not see the file and caches the result.

Any suggestions on how to only get a single copy in the file? I see no
option on the save command to append or not and my if exists does not seem
to do the trick.