Skip to content

Instantly share code, notes, and snippets.

@kenmazaika
Created December 18, 2012 20:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kenmazaika/4331610 to your computer and use it in GitHub Desktop.
Save kenmazaika/4331610 to your computer and use it in GitHub Desktop.
A mock omg_pull_request plugin
OmgPullRequest::Plugin.initialize do |args|
puts "initialize"
OmgPullRequest::Plugin.subscribe("closed") do |args|
puts "closed: #{args[:pull_request].number}"
end
OmgPullRequest::Plugin.subscribe("merged") do |args|
puts "merged: #{args[:pull_request].number}"
end
OmgPullRequest::Plugin.subscribe("run") do |args|
puts "run: #{args[:pull_request].number}"
end
end
initialize
run: 1256
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment