Searching for Email in a Text File
Submitted by lev_lafayette on Fri, 05/10/2013 - 23:28The following script searches through any specified text file for text before and after the ubiquitous email "@" symbol and outputs these as a csv file through use of grep, sed, and sort (for neatness). If the input or the output file are not specified, it exits after echoing the error and provides the correct exit code (1), to indicate error.