Last active
March 13, 2024 21:24
-
-
Save aptitudepi/a3a52fa293737aba0edc61ee6a0dc4d6 to your computer and use it in GitHub Desktop.
After downloading all emails from a folder in .eml format from ~~gmail~~ Thunderbird, format it such that every email is separated by a pipe (" | ") instead of a newline so that I can update the Gmail filter rule for new spam emails. Remember to check for false positives!
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
find . -type f -exec cat {} \; | nl | grep "From" | grep -o '[[:alnum:]+\.\_\-]*@[[:alnum:]+\.\_\-]*' | sort -fu | awk '{printf "%s | ",$0} END {print ""}' | rev | cut -c 4- | rev |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment