X-Git-Url: https://git.madduck.net/etc/mailfilter.git/blobdiff_plain/77da85a6358ffc97778ac2c06e3c9e803163f1c4..3d7d576505af2759a6227cec6bef322c688ec3f9:/procmail/defines diff --git a/procmail/defines b/procmail/defines index 62464dd..af431c1 100644 --- a/procmail/defines +++ b/procmail/defines @@ -36,9 +36,6 @@ TRAINER="$NICE $MAILFILT/bin/train" SQLITE="$NICE /usr/bin/sqlite3" -OURDATE="`date -R`" -OURDATE_SHORT=`date +%Y.%m.%d.%H.%M.%N` - BASE=$HOME/.maildir #DEFAULT="|$DELIVER" @@ -81,6 +78,20 @@ TICKLER_QUEUE=$BASE/.tickler/ DISCARD=$BASE/.discard/ #DISCARD="'|$DELIVER -m BASE.discard'" +OURDATE="`date +'%s %Y.%m.%d.%H.%M.%N %a, %d %b %Y %T %z'`" +:0 +*$ OURDATE ?? ^\/${RE_NOT_SPACE}+ +{ OURDATE_TS="$MATCH" } +:0 +*$ OURDATE ?? ^[0-9]+${RE_SPACE}+\/${RE_NOT_SPACE}+ +{ OURDATE_SHORT="$MATCH" } +:0 +*$ OURDATE ?? ^[0-9]+${RE_SPACE}+[0-9.]+${RE_SPACE}+\/${RE_NOT_SPACE}+ +{ OURDATE="$MATCH" } + +DELAY_NEXT_WEEKEND='next monday 54 hours ago' # fri night, 18:00 CET +DELAY_TONIGHT='tomorrow 00:00 6 hours ago' # tonight at 18:00 CET + ### variables from the message ### local recipient data @@ -133,6 +144,10 @@ INCLUDERC=$PMDIR/get-msgid *$ ^X-Tickle-Delivered:$RE_EXTRACT_HEADER_VALUE { TICKLE_DELIVERED="$MATCH" } +:0 +*$ ^X-Delayed:$RE_EXTRACT_HEADER_VALUE +{ DELAYED="$MATCH" } + # fix variable values for special cases INCLUDERC=$PMDIR/normalise