require ["vnd.dovecot.pipe", "copy", "imapsieve", "environment", "variables"]; if environment :matches "imap.mailbox" "*" { set "mailbox" "${1}"; } if anyof (string "${mailbox}" "Trash", string "${mailbox}" "junkmail", string "${mailbox}" "Junk", string "${mailbox}" "Éléments supprimés") { stop; } pipe :copy "learn-ham.sh";