Monday, February 1, 2010

email_pop_reader gem pushed to gemcutter

In one of my previous projects, I worked on ruby script to read the emails from mail-in database and process the emails as per the business requirement. In ruby, we have a libray called Net::POP3 which provides functionality for retrieving email via POP3. I went ahead with a thought of converting this to a gem.

The emails retrieved from mail-in database are stored in some sort of data structure to process further. The utility makes use of Net::POP3 and TMail libraries and provides with some handy methods such as 'retrieve emails' as array of hashes. The hash has email's from,to,cc,bcc,subject,body fields. Email body with attachment has not been considered for simplicity.

It also provides 'delete_emails(unique_email_ids=[])' method which takes array of unique email ids (retrieved with pop email unique_id) as parameter and deletes those.

Install :-

gem install email_pop_reader

(It has been pushed to http://gemcutter.org) - http://gemcutter.org/gems/email_pop_reader

OR

Download the gem file from http://github.com/NiranjanSarade/email-pop-reader.git/
gem install email_pop_reader-0.0.1.gem

No comments:

Post a Comment