X-Git-Url: https://git.madduck.net/etc/mailfilter.git/blobdiff_plain/ba62adb2c3d0d730f84572326c1cd6023231b705..b55ac0f2467f8f7502a88c843f37c0123029dd93:/procmail/deliver diff --git a/procmail/deliver b/procmail/deliver index e299423..af2f70c 100644 --- a/procmail/deliver +++ b/procmail/deliver @@ -23,6 +23,16 @@ *$ ! DEST ?? ^\. { DEST=".$DEST" } +:0 +* MARK_READ ?? . +{ + LOG="deliver: marking messages $MSGID as read because of $MARK_READ$NL" + TRAP="$TRAP; BASENAME=\"\${DESTFILE##*/}:2,S\"" + TRAP="$TRAP; DIRNAME=\"\${DESTFILE%/new/*}/cur\"" + TRAP="$TRAP; DESTFILE=\"\$DIRNAME/\$BASENAME\"" + TRAP="$TRAP; mv \"\$LASTFOLDER\" \"$BASE/\$DESTFILE\"" +} + :0 { LOG="deliver: delivering message $MSGID to $DEST$NL"