[Dovecot] How to know when a mail is moved from a folder to
darrinsmart at gmail.com
Wed Aug 17 13:01:26 EEST 2005
I do this by having a "razor submissions" folder as well as my normal
spamassassin-tagged spam goes into Junk.
other mail I identify as spam goes into Junk as well (via the Junk
mail button in Mail.app)
Every now and then I review the contents of Junk, take out any false
matches, and drag the rest into my "razor submissions folder".
Then I have a small script that runs every 2 minutes from cron, taking
each message from "razor submissions" and reporting it to spamassassin
(and razor, dcc etc)
Works fairly well.
cd $HOME/"Maildir/.Razor Submissions"
# Quick exit if lockfile exists
[ -e .submitting.lock ] && exit 0
lockfile -l60 .submitting.lock
for i in *; do
[ -e $i ] && mv $i ../cur/
for i in cur/*; do
[ -e $i ] && /usr/bin/spamassassin -r < $i && rm $i
rm -f .submitting.lock
More information about the dovecot