test-elseif-ref.siv 481 Bytes
Newer Older
Laurent Montel's avatar
Laurent Montel committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
require "subaddress";
require "fileinto";
require "imap4flags";

#SCRIPTNAME: Script part 0
if address :all :is "X-Delivered-To" "alias1@fastmail.fm"
{
    fileinto "INBOX.alias1";
    stop;
} elsif address :all :is "X-Delivered-To" "alias2@sent.com"
{
    setflag [ "\\Seen" ];
    fileinto "INBOX.alias2";
    stop;
} elsif address :all :is "X-Delivered-To" "alias3@eml.cc"
{
    fileinto "INBOX.alias3";
    stop;
} 

#SCRIPTNAME: Script part 1
redirect "another@account.net";
Laurent Montel's avatar
Laurent Montel committed
23