Skip to content

Instantly share code, notes, and snippets.

@awd
Created July 21, 2010 16:17
Show Gist options
  • Save awd/484703 to your computer and use it in GitHub Desktop.
Save awd/484703 to your computer and use it in GitHub Desktop.
namespace :woople do
desc "Continuous Integration Notification"
task :continuous_integration => :environment do
# CIJOE
# inline class
class CIMailer < MadMimiMailer
def mimi_blank_template(recipient, subject, message)
from "Woople Notifications <notifications@#{MAIN_HOST}>"
recipients recipient
subject subject
body ({ :message => message })
end
end
subject = "[CIJoe] Build #{ENV['STATUS']}: #{ENV['SHA']}"
message = "
This is a Public Service Announcement.
Author: #{ENV['AUTHOR'] || 'No Author'}
Message:
#{ENV['MESSAGE'] || 'No Message'}
#{ENV['OUTPUT'] || nil}
CIJoe: http://ci.bigbangtechnology.com
"
CIMailer.deliver_mimi_blank_template(ENV['RECIPIENT'], subject, message)
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment