Patrick Mylund Nielsen

EmailsFromFile

EmailsFromFile is a Python script that extracts all email addresses from a file. It follows a regular expression pattern based on the RFC 2822 standard and should thus return all valid email addresses regardless of how they appear in the file. For example, EmailsFromFile will distinguish between separate email addresses in a comma-separated list of values, such as a CSV file containing names, addresses, phone numbers and email addresses.

Download

Platform Version Package Size
All (Python) 1.1 – 2011-02-14 emailsfromfile.py (right-click -> Save as…) 1.8 KB
Git repository Development https://github.com/pmylund/emailsfromfile

Usage

python emailsfromfile.py <filename> [separator] [encoding]

The separator and encoding parameters are optional. The separator is a new line and the file encoding is 8-bit ASCII by default. If you want to specify an encoding, you also have to set a separator; to use a new line (the default), specify newline as the separator.

Examples:

Requirements

Notice

License

EmailsFromFile is licensed under the WTFPL.