I just found out about Pony, a Ruby gem for sending emails.
The cool thing about Pony is how simple it is. Good work, people!
Pony.mail(:to => 'email@example.com', :via => :smtp, :smtp => {
:host => 'smtp.example.com',
:port => '25',
:user => 'username',
:password => 'passkey',
:auth => :plain,
:domain => "example.com"
},
:from => 'me@example.com', :subject => 'hi', :body => 'Hello there.')
I'm planning on using this with Sinatra, but I'll probably end up using it with some Ruby scripts as well.
Speaking of which, I bought a book about using Ruby for systems administration awhile back. It had some really cool ideas in it, but I wasn't as comfortable with Ruby back then as I am now.
I definitely have to give this book a review!
More information: Ruby Pony @ Docunext