summaryrefslogtreecommitdiff
path: root/.maildirproc/default.rc
diff options
context:
space:
mode:
authorLuke Shumaker <LukeShu@sbcglobal.net>2012-05-22 23:46:29 -0400
committerLuke Shumaker <LukeShu@sbcglobal.net>2012-05-22 23:46:29 -0400
commitd26fda540c355fa37a1381b11765c47fdc5bd006 (patch)
treef6510335adf691d662cae765cb7f77dcdcbf4efc /.maildirproc/default.rc
parent3b8d4575218ab6d8e1155a81c45d81a8631aff25 (diff)
parent7036a9b36396ae49cf8ba0f8ad5fe139a65433c1 (diff)
Merge branch 'hp-dv6426us-par'
Conflicts: .crontab.local .git.info.exclude .wmii/wmiirc_local
Diffstat (limited to '.maildirproc/default.rc')
-rw-r--r--.maildirproc/default.rc19
1 files changed, 13 insertions, 6 deletions
diff --git a/.maildirproc/default.rc b/.maildirproc/default.rc
index d7351c5..f49fb9b 100644
--- a/.maildirproc/default.rc
+++ b/.maildirproc/default.rc
@@ -46,24 +46,25 @@ def handle_incoming_spam_training(mail):
def handle_incoming_ham_training(mail):
bogofilter_ham(mail)
- mail.move(".Ham")
+ handle_incoming_ham(mail)
def handle_incoming_ham(mail):
my_filters(mail)
+def handle_incoming_spam(mail):
+ mail.move(".Bulk Mail")
def handle_incoming_unknown(mail):
# Filter spam
spam = bogofilter_auto(mail)
if spam == 0:
- mail.move(".Bulk Mail")
+ handle_incoming_spam(mail)
return
elif spam == 1:
- mail.move(".Ham")
+ handle_incoming_ham(mail)
return
elif spam == 2:
# maybe spam
- my_filters(mail)
return
else:
mail.move(".Error")
@@ -231,7 +232,11 @@ def my_filters(mail):
mail.move(".CompTIA")
return
- if is_to_or_from(mail, "@lnnorthstar.org"):
+ if (
+ False
+ or is_to_or_from(mail, "@lnnorthstar.org")
+ or is_to_or_from(mail, "lnnorthstar.org@tigertech.net")
+ ):
mail.move(".School.Newspaper")
return
@@ -318,11 +323,13 @@ def my_filters(mail):
mail.move(".misc.accounts")
return
+ mail.move(".Ham")
+
handle_mapping = {
".": handle_incoming_unknown,
".spam-training": handle_incoming_spam_training,
".ham-training": handle_incoming_ham_training,
- ".Ham": handle_incoming_ham,
+ #".Ham": handle_incoming_ham,
}
processor.maildirs = handle_mapping.keys()
for mail in processor: