Process each line in a text file one line at a time