Created
January 23, 2010 03:11
-
-
Save cristibalan/284403 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'rubygems' | |
require 'mail' | |
Mail.defaults do | |
smtp "smtp.gmail.com" do | |
port 587 | |
enable_tls | |
user "[email protected]" | |
pass "yomommasobig" | |
helo "localhost.localdomain" | |
end | |
end | |
mail = Mail.deliver do | |
from "[email protected]" | |
to "[email protected]" | |
subject "grr, sending mail sux!" | |
text_part do | |
body "some text" | |
end | |
html_part do | |
content_type 'text/html; charset=UTF-8' | |
body "<h1>some html title</h1><p>aaa</p><p>bbb</p>" | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment