summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Denker <jsd@av8n.com>2012-07-17 07:02:45 -0700
committerJohn Denker <jsd@av8n.com>2012-07-29 15:32:32 -0700
commit1427af73b6837df40333f3b317e9ce1f5fde83cc (patch)
tree03a42f353094955ae429416ca473b65af65695d2
parent6cdc5c9d9caecba0e13264931824a9ac3cd3f738 (diff)
remove bad stuff from mailbox, sa-learn it, move it to ../spam/
-rwxr-xr-xtools/mail-zap13
1 files changed, 13 insertions, 0 deletions
diff --git a/tools/mail-zap b/tools/mail-zap
new file mode 100755
index 0000000..912d740
--- /dev/null
+++ b/tools/mail-zap
@@ -0,0 +1,13 @@
+#! /bin/bash
+
+if test -z "$*" ; then
+ exit
+fi
+
+mail-scan +subject "$@"
+
+sa-learn --spam "$@"
+
+for file in "$@" ; do
+ mv "$file" "$(dirname $file)/../spam/"
+done