posted 19 years ago
I would like to write a unix script using which I need to read all emails (using 'mail' command) and redirect each email to a separate file. I am facing challenges in passing options like 'n' (to go to next message), 'q' (to quit), 'd' (to delete a message) etc to 'mail' command within a script. Is there any ready made script available to handle these kind of interactive commands?
Thanks in advance.