Mail now in ActionMailer

OK everyone, so we finally have Mail merged into ActionMailer replacing out TMail

This is for the 3.0 release, and not part of the 2.x tree.

I am the TMail maintainer and I decided this year to write a ruby email handler, the Mail gem is my solution to this.

Mail takes a very object oriented approach to email. It conforms to RFCs as closely as practical and parses the 0.5gb Trec and 2.5Gb Enron email/spam database (about 500,000 emails) without crashing.

Anyone who has used TMail will appreciate things Mail does and you should not have too much trouble moving over. The only thing you need to keep in mind is that in mail, everything is an object, so you have to call :to_s to get string values. Mail also has :decoded and :encoded methods for every object which should help you out more.

Also, unlike ActionMailer’s vendoring of TMail, Mail is a gem dependency, so we can keep things up to date easily.

You can read about the Mail gem at:

http://lindsaar.net/2009/9/17/mail-tmail-the-future-of-ruby-email-handling

http://lindsaar.net/2009/10/28/new-mail-gem-released

http://lindsaar.net/2009/9/18/mail-and-bounced-emails

http://github.com/mikel/mail

The commit where Jeremy merged in my changes is at:

http://github.com/rails/rails/commit/b27a3e8da39484d8a02d3b9c1e4dc3cb60ddcce7

http://github.com/rails/rails/commit/71ffa760701d2240ece5f17b75df316611ecb3d0

Great post Mikel

Thanks for you hard work - i'm excited to read more.

Good stuff. Thanks Mikel!

Mikel Lindsaar wrote:

OK everyone, so we finally have Mail merged into ActionMailer replacing out TMail

This is for the 3.0 release, and not part of the 2.x tree.

Great! I wish it were already there :slight_smile: I've been using your gem a little and am quite happy with it.