[Dovecot] Sieve fileinto and year/month folders.

Stephan Bosch stephan at rename-it.nl
Wed Mar 28 19:31:31 EEST 2012


Op 3/28/2012 6:26 PM, Gregory Finch schreef:
> On 2012-03-28 9:04 AM, Stephan Bosch wrote:
>>
>> require ["variables","date","fileinto","mailbox"];
>>
>> # Extract date info
>> if currentdate :matches "year" "*" { set "year" "${1}"; }
>> if currentdate :matches "month" "*" { set "month" "${1}"; }
>>
>> # Archive Dovecot mailing list items by year and month.
>> # Create folder when it does not exist.
>> if header :is "list-id" "dovecot.dovecot.org" {
>>     fileinto :create "INBOX.mls.${year}.${month}.dovecot";
>> }
>>
>>
>> The above also uses a more reliable way to detect the Dovecot
>> mailinglist.
> Stephan,
>
> Is the "mailbox" extension the one that lets "fileinto" use ":create"?
> I've had a hard time trying to find a useful sieve reference that I can
> understand.
>
> Thank you,

Yes:

http://tools.ietf.org/html/rfc5490#section-3.2

You can find links to specifications of the various Sieve extensions 
implemented for Pigeonhole here:

http://pigeonhole.dovecot.org

Regards,

Stephan.


More information about the dovecot mailing list