Skip to content

Instantly share code, notes, and snippets.

@abyssluke
Last active August 2, 2016 20:45
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save abyssluke/b1225bfcca0399cc3d20e962596b599d to your computer and use it in GitHub Desktop.
Save abyssluke/b1225bfcca0399cc3d20e962596b599d to your computer and use it in GitHub Desktop.
Learn sylfilter/bsfilter & Submit to spamcop(for Sylpheed)
#!/bin/bash
if ls *.eml > /dev/null 2>&1; then
echo "Go spamcop!"
else
echo "404 eml not found"
exit 1
fi
echo "sylfilter status:"
sylfilter *.eml
echo "---"
echo "bsfilter status:"
bsfilter *.eml
echo "---"
echo "Learning spam"
echo -n "sylfilter..."
sylfilter -j *.eml
echo "OK"
echo -n "bsfilter..."
bsfilter -s -C -u *.eml
echo "OK"
echo "---"
echo -n "Launching Sylpheed..."
sylpheed --compose 'mailto:submit.YOURKEY@spam.spamcop.net?subject=spam' --attach *.eml
echo "OK"
exit 0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment