Re: set imap flags in user sieve scripts
Am 11.03.23 um 19:51 schrieb Felix Zielcke: Am Samstag, dem 11.03.2023 um 19:30 +0100 schrieb spi: 11.03.2023 19:23:21 Benny Pedersen : spi skrev den 2023-03-11 13:34: if address :domain "From" "whatever.com"{ fileinto :flags ["\\todo"] "working/whatever"; } require ["fileinto","imap4flags"]; imap4flags seems not to be accepted in an user script. My sieve editor shows an error. If I add require ["fileinto","imap4flags"]; to the script it just does not work. As said it works in a global script, but not an user one. Is imap4flags maybe listed in sieve_global_extensions setting in your config? That was is! Thanks, Removed it from sieve_global_extensions and it works smoothly now. Thanks again! Then you need to remove it from there: https://doc.dovecot.org/configuration_manual/sieve/configuration/#basic-configuration You could also try to enable it via sieve_extensions. But AIUI that shouldn't be needed. No, just removing from sieve_global_extensions did the job. -- Cheers spi
Re: set imap flags in user sieve scripts
Am Samstag, dem 11.03.2023 um 19:30 +0100 schrieb spi: > > 11.03.2023 19:23:21 Benny Pedersen : > > > spi skrev den 2023-03-11 13:34: > > > > > if address :domain "From" "whatever.com"{ > > > fileinto :flags ["\\todo"] "working/whatever"; > > > } > > > > require ["fileinto","imap4flags"]; > > imap4flags seems not to be accepted in an user script. My sieve > editor shows an error. If I add require ["fileinto","imap4flags"]; to > the script it just does not work. > > As said it works in a global script, but not an user one. > Is imap4flags maybe listed in sieve_global_extensions setting in your config? Then you need to remove it from there: https://doc.dovecot.org/configuration_manual/sieve/configuration/#basic-configuration You could also try to enable it via sieve_extensions. But AIUI that shouldn't be needed. >
Re: set imap flags in user sieve scripts
11.03.2023 19:23:21 Benny Pedersen : > spi skrev den 2023-03-11 13:34: > >> if address :domain "From" "whatever.com"{ >> fileinto :flags ["\\todo"] "working/whatever"; >> } > > require ["fileinto","imap4flags"]; imap4flags seems not to be accepted in an user script. My sieve editor shows an error. If I add require ["fileinto","imap4flags"]; to the script it just does not work. As said it works in a global script, but not an user one. > > # rule:[set todo] > if allof (header :contains "subject" "set imap flags in user sieve scripts", > header :contains "from" "u...@example.org", header :contains "to" > "dovecot@dovecot.org") > { > setflag "todo"; > fileinto "todofolder"; > stop; > } > > created in roundcube webmail
Re: set imap flags in user sieve scripts
spi skrev den 2023-03-11 13:34: if address :domain "From" "whatever.com"{ fileinto :flags ["\\todo"] "working/whatever"; } require ["fileinto","imap4flags"]; # rule:[set todo] if allof (header :contains "subject" "set imap flags in user sieve scripts", header :contains "from" "u...@example.org", header :contains "to" "dovecot@dovecot.org") { setflag "todo"; fileinto "todofolder"; stop; } created in roundcube webmail
set imap flags in user sieve scripts
Hi all Could anyone lead me into the right direction please? I use 'addflag ...' or 'fileinto :flags ...' in global sieve scripts to flag and sort incoming mail - that works. Trying to do that with custom user scripts doesn't work - I get the error that imap4flags only can be used in global scripts. Is there any way to get incoming mails labled and sorted by user sieve scripts? So something like this for a particular user doesn't work: if address :domain "From" "whatever.com"{ fileinto :flags ["\\todo"] "working/whatever"; } -- Cheers spi