Created
November 4, 2010 20:23
-
-
Save roelven/663124 to your computer and use it in GitHub Desktop.
Parse .eml files to retrieve emailaddresses
This file contains hidden or 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
## | |
## Parse a whole directory of .eml files | |
## and retrieve all printed emailaddresses, sort them, and remove duplicates | |
## and print to a file. | |
## | |
perl -wne'while(/[\w\.\-]+@[\w\.\-]+\w+/g){print "$&\n"}' *.* | sort -u > /tmp/output.txt |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Create a MySQL query to update table later with same expression: