X-Git-Url: https://feistymeow.org/gitweb/?a=blobdiff_plain;f=scripts%2Femail%2Fmove_spams_and_check.sh;h=ababe18e2e9d8a24db6b24522a0921e6b983b041;hb=2e93c29a45ae9d58694c0de962151e6829739380;hp=b7b4b8b21ba710e1e5db38b5b464badb518574cf;hpb=2952ccf47b80174880141a7ecfa122089f349b8d;p=feisty_meow.git diff --git a/scripts/email/move_spams_and_check.sh b/scripts/email/move_spams_and_check.sh index b7b4b8b2..ababe18e 100644 --- a/scripts/email/move_spams_and_check.sh +++ b/scripts/email/move_spams_and_check.sh @@ -6,15 +6,17 @@ # after the spam is all snagged, it is scanned for any untoward presence # of non-spam folks using the user's valid email list. +source "$FEISTY_MEOW_SCRIPTS/core/launch_feisty_meow.sh" + # the storage area that the spam catcher tool puts the suspected spam into. SPAM_SPOOL="/var/spool/sa-exim" # a temporary directory where we'll move all the spam for analysis. SPAM_HOLD="$HOME/spamcrud" # the white list needs to be a file of good email addresses that will # probably never send spam. it should be formatted one address to a line. -EMAIL_WHITE_LIST="$HOME/quartz/database/email_addresses.txt" +EMAIL_WHITE_LIST="$CLOUD_BASE/magic_cabinet/lists/email_addresses.txt" # we'll save a report of the spam checks in the file below. -REPORT_FILE="$HOME/spam_check_report.txt" +REPORT_FILE="$HOME/spam_check_report_$(date_stringer).txt" if [ ! -d "$SPAM_HOLD" ]; then mkdir "$SPAM_HOLD" @@ -28,8 +30,9 @@ fi echo "Setting the directory back to user's ownership..." sudo chown -R $USER "$SPAM_HOLD" sudo chgrp -R $USER "$SPAM_HOLD" -echo "Running checker for false-positive spams..." -bash "$SHELLDIR/email/scan_spam.sh" "$SPAM_HOLD" "$EMAIL_WHITE_LIST" 2>&1 \ - | tee "$REPORT_FILE" +echo "Checking for false-positive spams..." | tee "$REPORT_FILE" +bash "$FEISTY_MEOW_SCRIPTS/email/scan_spam.sh" "$SPAM_HOLD" "$EMAIL_WHITE_LIST" 2>&1 \ + | tee -a "$REPORT_FILE" +echo "Done checking for false-positive spams." | tee -a "$REPORT_FILE"