Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

[campfire] Don't ignore remote merges as they're most likely pulls

  • Loading branch information...
commit aa34d85d29688027b855d04e912a0dc32d3c22ef 1 parent 812a523
@defunkt defunkt authored
Showing with 3 additions and 3 deletions.
  1. +3 −3 services/campfire.rb
View
6 services/campfire.rb
@@ -6,16 +6,16 @@
throw(:halt, 400) unless campfire && campfire.login(data['email'], data['password'])
throw(:halt, 400) unless room = campfire.find_room_by_name(data['room'])
- if payload['commits'].last && payload['commits'].last['message'] =~ /^Merge/
+ if payload['commits'].last && payload['commits'].last['message'] =~ /^Merge/ && payload['commits'].last['message'] !~ /\sof\s/
commits = payload['commits'][-1, 1]
else
commits = payload['commits']
end
-
+
commits.each do |commit|
room.speak "[#{repository}/#{branch}] #{commit['message']} - #{commit['author']['name']} (#{commit['url']})"
end
-
+
room.leave
campfire.logout
end
Please sign in to comment.
Something went wrong with that request. Please try again.