This week's book giveaway is in the OO, Patterns, UML and Refactoring forum.
We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line!
See this thread for details.
The moose likes Linux / UNIX and the fly likes Read mail file using script Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

JavaRanch » Java Forums » Engineering » Linux / UNIX
Bookmark "Read mail file using script" Watch "Read mail file using script" New topic

Read mail file using script

sat kat

Joined: Feb 25, 2003
Posts: 5
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.
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link:
subject: Read mail file using script
It's not a secret anymore!