{"action":"created","comment":{"url":"https://api.github.com/repos/jpalmour/hubot-active-owner/pulls/comments/30849498","id":30849498,"diff_hunk":"@@ -4,31 +4,46 @@\n \n AOHelper = require '../ActiveOwnerHelper'\n Review = require '../Review'\n+Push = require '../Push'\n \n module.exports = (robot) ->\n \n   helper = new AOHelper robot\n+  branchPattern = ///^refs/heads/release-[0-9.]{5,6}$///\n \n   robot.router.post '/hubot/gh', (req, res) ->\n     robot.logger.debug 'GitHub webhook request received.'\n+    test = req.body.ref\n     res.send 200\n-    return if ! req.body.pull_request\n-    robot.logger.debug \"Processing pull_request event. \" +\n-      \"action: #{req.body.action}\"\n-    review = new Review(req.body)\n-    if req.body.action == 'labeled' &&\n-    req.body.label.name == process.env.HUBOT_REVIEW_NEEDED_LABEL\n+    \n+    return if ! (req.body.pull_request or req.body.forced == true)\n+    #console.log(process.stdout.write req.body) this is failing on testing for unknown reasons. \n+    robot.logger.debug \"Processing event. \" +\n+      \"action: #{req.body}\"","path":"src/robot-scripts/webhook-listener.coffee","position":25,"original_position":25,"commit_id":"cb387c41ce67363dd5784a3cddc4e15ab99a99e8","original_commit_id":"cb387c41ce67363dd5784a3cddc4e15ab99a99e8","user":{"login":"sakai135","id":1585689,"avatar_url":"https://avatars.githubusercontent.com/u/1585689?v=3","gravatar_id":"","url":"https://api.github.com/users/sakai135","html_url":"https://github.com/sakai135","followers_url":"https://api.github.com/users/sakai135/followers","following_url":"https://api.github.com/users/sakai135/following{/other_user}","gists_url":"https://api.github.com/users/sakai135/gists{/gist_id}","starred_url":"https://api.github.com/users/sakai135/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sakai135/subscriptions","organizations_url":"https://api.github.com/users/sakai135/orgs","repos_url":"https://api.github.com/users/sakai135/repos","events_url":"https://api.github.com/users/sakai135/events{/privacy}","received_events_url":"https://api.github.com/users/sakai135/received_events","type":"User","site_admin":false},"body":"Make a conditional log instead of logging the whole body","created_at":"2015-05-21T21:25:41Z","updated_at":"2015-05-21T21:25:41Z","html_url":"https://github.com/jpalmour/hubot-active-owner/pull/4#discussion_r30849498","pull_request_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/pulls/4","_links":{"self":{"href":"https://api.github.com/repos/jpalmour/hubot-active-owner/pulls/comments/30849498"},"html":{"href":"https://github.com/jpalmour/hubot-active-owner/pull/4#discussion_r30849498"},"pull_request":{"href":"https://api.github.com/repos/jpalmour/hubot-active-owner/pulls/4"}}},"pull_request":{"url":"https://api.github.com/repos/jpalmour/hubot-active-owner/pulls/4","id":35946266,"html_url":"https://github.com/jpalmour/hubot-active-owner/pull/4","diff_url":"https://github.com/jpalmour/hubot-active-owner/pull/4.diff","patch_url":"https://github.com/jpalmour/hubot-active-owner/pull/4.patch","issue_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/issues/4","number":4,"state":"open","locked":false,"title":"Adding in force push notification for SeaBone","user":{"login":"HannahWatwood","id":10118117,"avatar_url":"https://avatars.githubusercontent.com/u/10118117?v=3","gravatar_id":"","url":"https://api.github.com/users/HannahWatwood","html_url":"https://github.com/HannahWatwood","followers_url":"https://api.github.com/users/HannahWatwood/followers","following_url":"https://api.github.com/users/HannahWatwood/following{/other_user}","gists_url":"https://api.github.com/users/HannahWatwood/gists{/gist_id}","starred_url":"https://api.github.com/users/HannahWatwood/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/HannahWatwood/subscriptions","organizations_url":"https://api.github.com/users/HannahWatwood/orgs","repos_url":"https://api.github.com/users/HannahWatwood/repos","events_url":"https://api.github.com/users/HannahWatwood/events{/privacy}","received_events_url":"https://api.github.com/users/HannahWatwood/received_events","type":"User","site_admin":false},"body":"This is adding in Force Push notification for AOs. Will need alter web hook to also add in pull and push requests for this to work, but should be done after (staggered) deployment so we can verify. Will later need to add backup links so we can restore when someone force pushes. ","created_at":"2015-05-21T15:31:31Z","updated_at":"2015-05-21T21:25:41Z","closed_at":null,"merged_at":null,"merge_commit_sha":"3305aa51f59d11e25d2bcaf7b0b1f1d3efa10bf7","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/pulls/4/commits","review_comments_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/pulls/4/comments","review_comment_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/pulls/comments{/number}","comments_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/issues/4/comments","statuses_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/statuses/cb387c41ce67363dd5784a3cddc4e15ab99a99e8","head":{"label":"HannahWatwood:master","ref":"master","sha":"cb387c41ce67363dd5784a3cddc4e15ab99a99e8","user":{"login":"HannahWatwood","id":10118117,"avatar_url":"https://avatars.githubusercontent.com/u/10118117?v=3","gravatar_id":"","url":"https://api.github.com/users/HannahWatwood","html_url":"https://github.com/HannahWatwood","followers_url":"https://api.github.com/users/HannahWatwood/followers","following_url":"https://api.github.com/users/HannahWatwood/following{/other_user}","gists_url":"https://api.github.com/users/HannahWatwood/gists{/gist_id}","starred_url":"https://api.github.com/users/HannahWatwood/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/HannahWatwood/subscriptions","organizations_url":"https://api.github.com/users/HannahWatwood/orgs","repos_url":"https://api.github.com/users/HannahWatwood/repos","events_url":"https://api.github.com/users/HannahWatwood/events{/privacy}","received_events_url":"https://api.github.com/users/HannahWatwood/received_events","type":"User","site_admin":false},"repo":{"id":35232736,"name":"hubot-active-owner","full_name":"HannahWatwood/hubot-active-owner","owner":{"login":"HannahWatwood","id":10118117,"avatar_url":"https://avatars.githubusercontent.com/u/10118117?v=3","gravatar_id":"","url":"https://api.github.com/users/HannahWatwood","html_url":"https://github.com/HannahWatwood","followers_url":"https://api.github.com/users/HannahWatwood/followers","following_url":"https://api.github.com/users/HannahWatwood/following{/other_user}","gists_url":"https://api.github.com/users/HannahWatwood/gists{/gist_id}","starred_url":"https://api.github.com/users/HannahWatwood/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/HannahWatwood/subscriptions","organizations_url":"https://api.github.com/users/HannahWatwood/orgs","repos_url":"https://api.github.com/users/HannahWatwood/repos","events_url":"https://api.github.com/users/HannahWatwood/events{/privacy}","received_events_url":"https://api.github.com/users/HannahWatwood/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/HannahWatwood/hubot-active-owner","description":"Let hubot keep track of who is on AO duty for each team. ","fork":true,"url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner","forks_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/forks","keys_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/keys{/key_id}","collaborators_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/teams","hooks_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/hooks","issue_events_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/issues/events{/number}","events_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/events","assignees_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/assignees{/user}","branches_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/branches{/branch}","tags_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/tags","blobs_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/git/refs{/sha}","trees_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/git/trees{/sha}","statuses_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/statuses/{sha}","languages_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/languages","stargazers_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/stargazers","contributors_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/contributors","subscribers_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/subscribers","subscription_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/subscription","commits_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/commits{/sha}","git_commits_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/git/commits{/sha}","comments_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/comments{/number}","issue_comment_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/issues/comments{/number}","contents_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/contents/{+path}","compare_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/compare/{base}...{head}","merges_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/merges","archive_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/downloads","issues_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/issues{/number}","pulls_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/pulls{/number}","milestones_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/milestones{/number}","notifications_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/labels{/name}","releases_url":"https://api.github.com/repos/HannahWatwood/hubot-active-owner/releases{/id}","created_at":"2015-05-07T17:05:57Z","updated_at":"2015-05-07T17:05:57Z","pushed_at":"2015-05-21T15:27:56Z","git_url":"git://github.com/HannahWatwood/hubot-active-owner.git","ssh_url":"git@github.com:HannahWatwood/hubot-active-owner.git","clone_url":"https://github.com/HannahWatwood/hubot-active-owner.git","svn_url":"https://github.com/HannahWatwood/hubot-active-owner","homepage":null,"size":113,"stargazers_count":0,"watchers_count":0,"language":"CoffeeScript","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"jpalmour:master","ref":"master","sha":"227387531a66495183518a68cdb8fe76cd70df39","user":{"login":"jpalmour","id":1120916,"avatar_url":"https://avatars.githubusercontent.com/u/1120916?v=3","gravatar_id":"","url":"https://api.github.com/users/jpalmour","html_url":"https://github.com/jpalmour","followers_url":"https://api.github.com/users/jpalmour/followers","following_url":"https://api.github.com/users/jpalmour/following{/other_user}","gists_url":"https://api.github.com/users/jpalmour/gists{/gist_id}","starred_url":"https://api.github.com/users/jpalmour/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jpalmour/subscriptions","organizations_url":"https://api.github.com/users/jpalmour/orgs","repos_url":"https://api.github.com/users/jpalmour/repos","events_url":"https://api.github.com/users/jpalmour/events{/privacy}","received_events_url":"https://api.github.com/users/jpalmour/received_events","type":"User","site_admin":false},"repo":{"id":26883022,"name":"hubot-active-owner","full_name":"jpalmour/hubot-active-owner","owner":{"login":"jpalmour","id":1120916,"avatar_url":"https://avatars.githubusercontent.com/u/1120916?v=3","gravatar_id":"","url":"https://api.github.com/users/jpalmour","html_url":"https://github.com/jpalmour","followers_url":"https://api.github.com/users/jpalmour/followers","following_url":"https://api.github.com/users/jpalmour/following{/other_user}","gists_url":"https://api.github.com/users/jpalmour/gists{/gist_id}","starred_url":"https://api.github.com/users/jpalmour/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jpalmour/subscriptions","organizations_url":"https://api.github.com/users/jpalmour/orgs","repos_url":"https://api.github.com/users/jpalmour/repos","events_url":"https://api.github.com/users/jpalmour/events{/privacy}","received_events_url":"https://api.github.com/users/jpalmour/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jpalmour/hubot-active-owner","description":"Let hubot keep track of who is on AO duty for each team. ","fork":false,"url":"https://api.github.com/repos/jpalmour/hubot-active-owner","forks_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/forks","keys_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/teams","hooks_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/hooks","issue_events_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/issues/events{/number}","events_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/events","assignees_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/assignees{/user}","branches_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/branches{/branch}","tags_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/tags","blobs_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/git/refs{/sha}","trees_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/statuses/{sha}","languages_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/languages","stargazers_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/stargazers","contributors_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/contributors","subscribers_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/subscribers","subscription_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/subscription","commits_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/commits{/sha}","git_commits_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/git/commits{/sha}","comments_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/comments{/number}","issue_comment_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/issues/comments{/number}","contents_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/contents/{+path}","compare_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/merges","archive_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/downloads","issues_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/issues{/number}","pulls_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/pulls{/number}","milestones_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/milestones{/number}","notifications_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/labels{/name}","releases_url":"https://api.github.com/repos/jpalmour/hubot-active-owner/releases{/id}","created_at":"2014-11-19T21:42:37Z","updated_at":"2014-12-29T14:48:46Z","pushed_at":"2015-05-21T15:31:32Z","git_url":"git://github.com/jpalmour/hubot-active-owner.git","ssh_url":"git@github.com:jpalmour/hubot-active-owner.git","clone_url":"https://github.com/jpalmour/hubot-active-owner.git","svn_url":"https://github.com/jpalmour/hubot-active-owner","homepage":null,"size":261,"stargazers_count":0,"watchers_count":0,"language":"CoffeeScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":1,"forks":2,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/jpalmour/hubot-active-owner/pulls/4"},"html":{"href":"https://github.com/jpalmour/hubot-active-owner/pull/4"},"issue":{"href":"https://api.github.com/repos/jpalmour/hubot-active-owner/issues/4"},"comments":{"href":"https://api.github.com/repos/jpalmour/hubot-active-owner/issues/4/comments"},"review_comments":{"href":"https://api.github.com/repos/jpalmour/hubot-active-owner/pulls/4/comments"},"review_comment":{"href":"https://api.github.com/repos/jpalmour/hubot-active-owner/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/jpalmour/hubot-active-owner/pulls/4/commits"},"statuses":{"href":"https://api.github.com/repos/jpalmour/hubot-active-owner/statuses/cb387c41ce67363dd5784a3cddc4e15ab99a99e8"}}}}