Permalink
Browse files

Merge branch 'master' of https://github.com/jmazzi/github-services in…

…to jmazzi-master
  • Loading branch information...
technoweenie committed Mar 1, 2011
2 parents 1c81908 + 255f469 commit edc0dbb2e1cce3193ffc7a2e0a0eb1281394ee06
Showing with 9 additions and 0 deletions.
  1. +1 −0 CONTRIBUTORS
  2. +8 −0 services/email.rb
View
@@ -56,3 +56,4 @@ Thanks to the following people for making this possible
- Alex Ezell
- Serge Smetana
- Matthias Viehweger
- Justin Mazzi
View
@@ -23,6 +23,12 @@
EOH
if payload['commits'].size > 1
last_commit_sha = payload['commits'].last['id'][0..5]
before_commit_sha = payload['before'][0..5]
compare_link = "Compare View #{payload['repository']['url']}/compare/#{before_commit_sha}...#{last_commit_sha}"
end
payload['commits'].each do |commit|
gitsha = commit['id']
added = commit['added'].map { |f| ['A', f] }
@@ -59,6 +65,8 @@
EOH
end
body << compare_link unless compare_link.nil?
begin
message = TMail::Mail.new
message.set_content_type('text', 'plain', {:charset => 'UTF-8'})

0 comments on commit edc0dbb

Please sign in to comment.