Aici veti gasi detalii tehnice despre cum se pot realiza configurari software+ hardware.
Here you can find tehnical details about software/hardware configuration.

luni, 28 martie 2011

Extract mail addreses from files or downloaded site

======================================
grep -Eiorh '([[:alnum:]_.]+@[[:alnum:]_]+?\.[[:alpha:].]{2,6})' ./ > emails.txt
======================================

This makes grep find all email addresses and write them to file emails.txt in the current dir.
-E makes grep use extended regular expressions
-i does a case-insensitive match
-o makes grep return only the matching part of the line and not the whole line
-r makes grep look files recursively
-h stops grep from outputting the filename where the match was found

with the r parameter and the source file as ./ grep will go through all the files in the current directory and sub directories. The weird looking string in the line is the regular expression which looks for emails.

Map


Visitor Map