{"action":"created","comment":{"url":"https://api.github.com/repos/SUSE/TeamDashboard/pulls/comments/45071355","id":45071355,"diff_hunk":"@@ -11,7 +11,7 @@ class GithubController < ApplicationController\n   def pulls\n     @requests = Rails.cache.fetch \"github_pulls_#{@repo}\", expires_in: 15.minute do\n       @prs.get_all(@repo).each do |pr|\n-        captures = pr.title.split(/ /)\n+        captures = pr.title.split(/[_ -#\\.]/)\n         card_id  = captures.last.to_i","path":"app/controllers/github_controller.rb","position":6,"original_position":6,"commit_id":"f6e1dcacfa1dcfafbb04eb57fb703622aa111310","original_commit_id":"f6e1dcacfa1dcfafbb04eb57fb703622aa111310","user":{"login":"kirushik","id":152719,"avatar_url":"https://avatars.githubusercontent.com/u/152719?v=3","gravatar_id":"","url":"https://api.github.com/users/kirushik","html_url":"https://github.com/kirushik","followers_url":"https://api.github.com/users/kirushik/followers","following_url":"https://api.github.com/users/kirushik/following{/other_user}","gists_url":"https://api.github.com/users/kirushik/gists{/gist_id}","starred_url":"https://api.github.com/users/kirushik/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kirushik/subscriptions","organizations_url":"https://api.github.com/users/kirushik/orgs","repos_url":"https://api.github.com/users/kirushik/repos","events_url":"https://api.github.com/users/kirushik/events{/privacy}","received_events_url":"https://api.github.com/users/kirushik/received_events","type":"User","site_admin":false},"body":"I really advise you to just chop off the ending digits from the string.\r\n```ruby\r\ncard_id = pr.title.match(/\\d+$/).first\r\n```\r\nor something like that.","created_at":"2015-11-17T15:17:16Z","updated_at":"2015-11-17T15:17:16Z","html_url":"https://github.com/SUSE/TeamDashboard/pull/25#discussion_r45071355","pull_request_url":"https://api.github.com/repos/SUSE/TeamDashboard/pulls/25","_links":{"self":{"href":"https://api.github.com/repos/SUSE/TeamDashboard/pulls/comments/45071355"},"html":{"href":"https://github.com/SUSE/TeamDashboard/pull/25#discussion_r45071355"},"pull_request":{"href":"https://api.github.com/repos/SUSE/TeamDashboard/pulls/25"}}},"pull_request":{"url":"https://api.github.com/repos/SUSE/TeamDashboard/pulls/25","id":50941414,"html_url":"https://github.com/SUSE/TeamDashboard/pull/25","diff_url":"https://github.com/SUSE/TeamDashboard/pull/25.diff","patch_url":"https://github.com/SUSE/TeamDashboard/pull/25.patch","issue_url":"https://api.github.com/repos/SUSE/TeamDashboard/issues/25","number":25,"state":"open","locked":false,"title":"detect trello card ids in pr titles with leading underscore","user":{"login":"felixsch","id":4460715,"avatar_url":"https://avatars.githubusercontent.com/u/4460715?v=3","gravatar_id":"","url":"https://api.github.com/users/felixsch","html_url":"https://github.com/felixsch","followers_url":"https://api.github.com/users/felixsch/followers","following_url":"https://api.github.com/users/felixsch/following{/other_user}","gists_url":"https://api.github.com/users/felixsch/gists{/gist_id}","starred_url":"https://api.github.com/users/felixsch/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/felixsch/subscriptions","organizations_url":"https://api.github.com/users/felixsch/orgs","repos_url":"https://api.github.com/users/felixsch/repos","events_url":"https://api.github.com/users/felixsch/events{/privacy}","received_events_url":"https://api.github.com/users/felixsch/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-11-17T12:37:55Z","updated_at":"2015-11-17T15:17:16Z","closed_at":null,"merged_at":null,"merge_commit_sha":"c147c9a5e684370cca234ea046cee53f87c4e55e","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/SUSE/TeamDashboard/pulls/25/commits","review_comments_url":"https://api.github.com/repos/SUSE/TeamDashboard/pulls/25/comments","review_comment_url":"https://api.github.com/repos/SUSE/TeamDashboard/pulls/comments{/number}","comments_url":"https://api.github.com/repos/SUSE/TeamDashboard/issues/25/comments","statuses_url":"https://api.github.com/repos/SUSE/TeamDashboard/statuses/f6e1dcacfa1dcfafbb04eb57fb703622aa111310","head":{"label":"SUSE:fix-trello-card-detection-regex","ref":"fix-trello-card-detection-regex","sha":"f6e1dcacfa1dcfafbb04eb57fb703622aa111310","user":{"login":"SUSE","id":1067733,"avatar_url":"https://avatars.githubusercontent.com/u/1067733?v=3","gravatar_id":"","url":"https://api.github.com/users/SUSE","html_url":"https://github.com/SUSE","followers_url":"https://api.github.com/users/SUSE/followers","following_url":"https://api.github.com/users/SUSE/following{/other_user}","gists_url":"https://api.github.com/users/SUSE/gists{/gist_id}","starred_url":"https://api.github.com/users/SUSE/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SUSE/subscriptions","organizations_url":"https://api.github.com/users/SUSE/orgs","repos_url":"https://api.github.com/users/SUSE/repos","events_url":"https://api.github.com/users/SUSE/events{/privacy}","received_events_url":"https://api.github.com/users/SUSE/received_events","type":"Organization","site_admin":false},"repo":{"id":27915376,"name":"TeamDashboard","full_name":"SUSE/TeamDashboard","owner":{"login":"SUSE","id":1067733,"avatar_url":"https://avatars.githubusercontent.com/u/1067733?v=3","gravatar_id":"","url":"https://api.github.com/users/SUSE","html_url":"https://github.com/SUSE","followers_url":"https://api.github.com/users/SUSE/followers","following_url":"https://api.github.com/users/SUSE/following{/other_user}","gists_url":"https://api.github.com/users/SUSE/gists{/gist_id}","starred_url":"https://api.github.com/users/SUSE/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SUSE/subscriptions","organizations_url":"https://api.github.com/users/SUSE/orgs","repos_url":"https://api.github.com/users/SUSE/repos","events_url":"https://api.github.com/users/SUSE/events{/privacy}","received_events_url":"https://api.github.com/users/SUSE/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/SUSE/TeamDashboard","description":"","fork":false,"url":"https://api.github.com/repos/SUSE/TeamDashboard","forks_url":"https://api.github.com/repos/SUSE/TeamDashboard/forks","keys_url":"https://api.github.com/repos/SUSE/TeamDashboard/keys{/key_id}","collaborators_url":"https://api.github.com/repos/SUSE/TeamDashboard/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/SUSE/TeamDashboard/teams","hooks_url":"https://api.github.com/repos/SUSE/TeamDashboard/hooks","issue_events_url":"https://api.github.com/repos/SUSE/TeamDashboard/issues/events{/number}","events_url":"https://api.github.com/repos/SUSE/TeamDashboard/events","assignees_url":"https://api.github.com/repos/SUSE/TeamDashboard/assignees{/user}","branches_url":"https://api.github.com/repos/SUSE/TeamDashboard/branches{/branch}","tags_url":"https://api.github.com/repos/SUSE/TeamDashboard/tags","blobs_url":"https://api.github.com/repos/SUSE/TeamDashboard/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/SUSE/TeamDashboard/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/SUSE/TeamDashboard/git/refs{/sha}","trees_url":"https://api.github.com/repos/SUSE/TeamDashboard/git/trees{/sha}","statuses_url":"https://api.github.com/repos/SUSE/TeamDashboard/statuses/{sha}","languages_url":"https://api.github.com/repos/SUSE/TeamDashboard/languages","stargazers_url":"https://api.github.com/repos/SUSE/TeamDashboard/stargazers","contributors_url":"https://api.github.com/repos/SUSE/TeamDashboard/contributors","subscribers_url":"https://api.github.com/repos/SUSE/TeamDashboard/subscribers","subscription_url":"https://api.github.com/repos/SUSE/TeamDashboard/subscription","commits_url":"https://api.github.com/repos/SUSE/TeamDashboard/commits{/sha}","git_commits_url":"https://api.github.com/repos/SUSE/TeamDashboard/git/commits{/sha}","comments_url":"https://api.github.com/repos/SUSE/TeamDashboard/comments{/number}","issue_comment_url":"https://api.github.com/repos/SUSE/TeamDashboard/issues/comments{/number}","contents_url":"https://api.github.com/repos/SUSE/TeamDashboard/contents/{+path}","compare_url":"https://api.github.com/repos/SUSE/TeamDashboard/compare/{base}...{head}","merges_url":"https://api.github.com/repos/SUSE/TeamDashboard/merges","archive_url":"https://api.github.com/repos/SUSE/TeamDashboard/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/SUSE/TeamDashboard/downloads","issues_url":"https://api.github.com/repos/SUSE/TeamDashboard/issues{/number}","pulls_url":"https://api.github.com/repos/SUSE/TeamDashboard/pulls{/number}","milestones_url":"https://api.github.com/repos/SUSE/TeamDashboard/milestones{/number}","notifications_url":"https://api.github.com/repos/SUSE/TeamDashboard/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/SUSE/TeamDashboard/labels{/name}","releases_url":"https://api.github.com/repos/SUSE/TeamDashboard/releases{/id}","created_at":"2014-12-12T10:10:59Z","updated_at":"2015-08-28T13:22:27Z","pushed_at":"2015-11-17T12:37:55Z","git_url":"git://github.com/SUSE/TeamDashboard.git","ssh_url":"git@github.com:SUSE/TeamDashboard.git","clone_url":"https://github.com/SUSE/TeamDashboard.git","svn_url":"https://github.com/SUSE/TeamDashboard","homepage":null,"size":3882,"stargazers_count":1,"watchers_count":1,"language":"CSS","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":1,"default_branch":"master"}},"base":{"label":"SUSE:master","ref":"master","sha":"2525308556aa984d5845cea9d7eef2072e67408f","user":{"login":"SUSE","id":1067733,"avatar_url":"https://avatars.githubusercontent.com/u/1067733?v=3","gravatar_id":"","url":"https://api.github.com/users/SUSE","html_url":"https://github.com/SUSE","followers_url":"https://api.github.com/users/SUSE/followers","following_url":"https://api.github.com/users/SUSE/following{/other_user}","gists_url":"https://api.github.com/users/SUSE/gists{/gist_id}","starred_url":"https://api.github.com/users/SUSE/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SUSE/subscriptions","organizations_url":"https://api.github.com/users/SUSE/orgs","repos_url":"https://api.github.com/users/SUSE/repos","events_url":"https://api.github.com/users/SUSE/events{/privacy}","received_events_url":"https://api.github.com/users/SUSE/received_events","type":"Organization","site_admin":false},"repo":{"id":27915376,"name":"TeamDashboard","full_name":"SUSE/TeamDashboard","owner":{"login":"SUSE","id":1067733,"avatar_url":"https://avatars.githubusercontent.com/u/1067733?v=3","gravatar_id":"","url":"https://api.github.com/users/SUSE","html_url":"https://github.com/SUSE","followers_url":"https://api.github.com/users/SUSE/followers","following_url":"https://api.github.com/users/SUSE/following{/other_user}","gists_url":"https://api.github.com/users/SUSE/gists{/gist_id}","starred_url":"https://api.github.com/users/SUSE/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SUSE/subscriptions","organizations_url":"https://api.github.com/users/SUSE/orgs","repos_url":"https://api.github.com/users/SUSE/repos","events_url":"https://api.github.com/users/SUSE/events{/privacy}","received_events_url":"https://api.github.com/users/SUSE/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/SUSE/TeamDashboard","description":"","fork":false,"url":"https://api.github.com/repos/SUSE/TeamDashboard","forks_url":"https://api.github.com/repos/SUSE/TeamDashboard/forks","keys_url":"https://api.github.com/repos/SUSE/TeamDashboard/keys{/key_id}","collaborators_url":"https://api.github.com/repos/SUSE/TeamDashboard/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/SUSE/TeamDashboard/teams","hooks_url":"https://api.github.com/repos/SUSE/TeamDashboard/hooks","issue_events_url":"https://api.github.com/repos/SUSE/TeamDashboard/issues/events{/number}","events_url":"https://api.github.com/repos/SUSE/TeamDashboard/events","assignees_url":"https://api.github.com/repos/SUSE/TeamDashboard/assignees{/user}","branches_url":"https://api.github.com/repos/SUSE/TeamDashboard/branches{/branch}","tags_url":"https://api.github.com/repos/SUSE/TeamDashboard/tags","blobs_url":"https://api.github.com/repos/SUSE/TeamDashboard/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/SUSE/TeamDashboard/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/SUSE/TeamDashboard/git/refs{/sha}","trees_url":"https://api.github.com/repos/SUSE/TeamDashboard/git/trees{/sha}","statuses_url":"https://api.github.com/repos/SUSE/TeamDashboard/statuses/{sha}","languages_url":"https://api.github.com/repos/SUSE/TeamDashboard/languages","stargazers_url":"https://api.github.com/repos/SUSE/TeamDashboard/stargazers","contributors_url":"https://api.github.com/repos/SUSE/TeamDashboard/contributors","subscribers_url":"https://api.github.com/repos/SUSE/TeamDashboard/subscribers","subscription_url":"https://api.github.com/repos/SUSE/TeamDashboard/subscription","commits_url":"https://api.github.com/repos/SUSE/TeamDashboard/commits{/sha}","git_commits_url":"https://api.github.com/repos/SUSE/TeamDashboard/git/commits{/sha}","comments_url":"https://api.github.com/repos/SUSE/TeamDashboard/comments{/number}","issue_comment_url":"https://api.github.com/repos/SUSE/TeamDashboard/issues/comments{/number}","contents_url":"https://api.github.com/repos/SUSE/TeamDashboard/contents/{+path}","compare_url":"https://api.github.com/repos/SUSE/TeamDashboard/compare/{base}...{head}","merges_url":"https://api.github.com/repos/SUSE/TeamDashboard/merges","archive_url":"https://api.github.com/repos/SUSE/TeamDashboard/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/SUSE/TeamDashboard/downloads","issues_url":"https://api.github.com/repos/SUSE/TeamDashboard/issues{/number}","pulls_url":"https://api.github.com/repos/SUSE/TeamDashboard/pulls{/number}","milestones_url":"https://api.github.com/repos/SUSE/TeamDashboard/milestones{/number}","notifications_url":"https://api.github.com/repos/SUSE/TeamDashboard/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/SUSE/TeamDashboard/labels{/name}","releases_url":"https://api.github.com/repos/SUSE/TeamDashboard/releases{/id}","created_at":"2014-12-12T10:10:59Z","updated_at":"2015-08-28T13:22:27Z","pushed_at":"2015-11-17T12:37:55Z","git_url":"git://github.com/SUSE/TeamDashboard.git","ssh_url":"git@github.com:SUSE/TeamDashboard.git","clone_url":"https://github.com/SUSE/TeamDashboard.git","svn_url":"https://github.com/SUSE/TeamDashboard","homepage":null,"size":3882,"stargazers_count":1,"watchers_count":1,"language":"CSS","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":1,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/SUSE/TeamDashboard/pulls/25"},"html":{"href":"https://github.com/SUSE/TeamDashboard/pull/25"},"issue":{"href":"https://api.github.com/repos/SUSE/TeamDashboard/issues/25"},"comments":{"href":"https://api.github.com/repos/SUSE/TeamDashboard/issues/25/comments"},"review_comments":{"href":"https://api.github.com/repos/SUSE/TeamDashboard/pulls/25/comments"},"review_comment":{"href":"https://api.github.com/repos/SUSE/TeamDashboard/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/SUSE/TeamDashboard/pulls/25/commits"},"statuses":{"href":"https://api.github.com/repos/SUSE/TeamDashboard/statuses/f6e1dcacfa1dcfafbb04eb57fb703622aa111310"}}}}