{"action":"created","comment":{"url":"https://api.github.com/repos/composer/packagist/pulls/comments/42776694","id":42776694,"diff_hunk":"@@ -111,7 +111,7 @@ public function updatePackageAction(Request $request)\n         }\n \n         if (isset($payload['repository']['url'])) { // github/gitlab/anything hook\n-            $urlRegex = '{^(?:ssh://git@|https?://|git://|git@)?(?P<host>[a-z0-9.-]+)[:/](?P<path>[\\w.-]+/[\\w.-]+?)(?:\\.git)?$}i';\n+            $urlRegex = '{^(?:ssh://git@|https?://|git://|git@)?(?P<host>[a-z0-9.-]+):(?:[0-9]+)?/(?P<path>[\\w.-]+/[\\w.-]+?)(?:\\.git)?$}i';","path":"src/Packagist/WebBundle/Controller/ApiController.php","position":5,"original_position":5,"commit_id":"a3d4425891342ecd26513dc6ccfc53d692d4eb48","original_commit_id":"a3d4425891342ecd26513dc6ccfc53d692d4eb48","user":{"login":"stof","id":439401,"avatar_url":"https://avatars.githubusercontent.com/u/439401?v=3","gravatar_id":"","url":"https://api.github.com/users/stof","html_url":"https://github.com/stof","followers_url":"https://api.github.com/users/stof/followers","following_url":"https://api.github.com/users/stof/following{/other_user}","gists_url":"https://api.github.com/users/stof/gists{/gist_id}","starred_url":"https://api.github.com/users/stof/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stof/subscriptions","organizations_url":"https://api.github.com/users/stof/orgs","repos_url":"https://api.github.com/users/stof/repos","events_url":"https://api.github.com/users/stof/events{/privacy}","received_events_url":"https://api.github.com/users/stof/received_events","type":"User","site_admin":false},"body":"this change breaks all URLs which don't have the port in them","created_at":"2015-10-22T17:13:42Z","updated_at":"2015-10-22T17:13:42Z","html_url":"https://github.com/composer/packagist/pull/599#discussion_r42776694","pull_request_url":"https://api.github.com/repos/composer/packagist/pulls/599","_links":{"self":{"href":"https://api.github.com/repos/composer/packagist/pulls/comments/42776694"},"html":{"href":"https://github.com/composer/packagist/pull/599#discussion_r42776694"},"pull_request":{"href":"https://api.github.com/repos/composer/packagist/pulls/599"}}},"pull_request":{"url":"https://api.github.com/repos/composer/packagist/pulls/599","id":48480330,"html_url":"https://github.com/composer/packagist/pull/599","diff_url":"https://github.com/composer/packagist/pull/599.diff","patch_url":"https://github.com/composer/packagist/pull/599.patch","issue_url":"https://api.github.com/repos/composer/packagist/issues/599","number":599,"state":"open","locked":false,"title":"Allow (optional) port number in repository URL","user":{"login":"kornrunner","id":725986,"avatar_url":"https://avatars.githubusercontent.com/u/725986?v=3","gravatar_id":"","url":"https://api.github.com/users/kornrunner","html_url":"https://github.com/kornrunner","followers_url":"https://api.github.com/users/kornrunner/followers","following_url":"https://api.github.com/users/kornrunner/following{/other_user}","gists_url":"https://api.github.com/users/kornrunner/gists{/gist_id}","starred_url":"https://api.github.com/users/kornrunner/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kornrunner/subscriptions","organizations_url":"https://api.github.com/users/kornrunner/orgs","repos_url":"https://api.github.com/users/kornrunner/repos","events_url":"https://api.github.com/users/kornrunner/events{/privacy}","received_events_url":"https://api.github.com/users/kornrunner/received_events","type":"User","site_admin":false},"body":"This allows us to create webhooks for URLs that have port numbers in them (specifically `ssh://` running under custom port).\r\n\r\nI've added the test as well, but haven't run them, haven't set it up properly yet.","created_at":"2015-10-22T16:26:05Z","updated_at":"2015-10-22T17:13:42Z","closed_at":null,"merged_at":null,"merge_commit_sha":"9cca7fa0db3356af2f99498729fc1f3c5aff2153","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/composer/packagist/pulls/599/commits","review_comments_url":"https://api.github.com/repos/composer/packagist/pulls/599/comments","review_comment_url":"https://api.github.com/repos/composer/packagist/pulls/comments{/number}","comments_url":"https://api.github.com/repos/composer/packagist/issues/599/comments","statuses_url":"https://api.github.com/repos/composer/packagist/statuses/a3d4425891342ecd26513dc6ccfc53d692d4eb48","head":{"label":"kornrunner:master","ref":"master","sha":"a3d4425891342ecd26513dc6ccfc53d692d4eb48","user":{"login":"kornrunner","id":725986,"avatar_url":"https://avatars.githubusercontent.com/u/725986?v=3","gravatar_id":"","url":"https://api.github.com/users/kornrunner","html_url":"https://github.com/kornrunner","followers_url":"https://api.github.com/users/kornrunner/followers","following_url":"https://api.github.com/users/kornrunner/following{/other_user}","gists_url":"https://api.github.com/users/kornrunner/gists{/gist_id}","starred_url":"https://api.github.com/users/kornrunner/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kornrunner/subscriptions","organizations_url":"https://api.github.com/users/kornrunner/orgs","repos_url":"https://api.github.com/users/kornrunner/repos","events_url":"https://api.github.com/users/kornrunner/events{/privacy}","received_events_url":"https://api.github.com/users/kornrunner/received_events","type":"User","site_admin":false},"repo":{"id":44734695,"name":"packagist","full_name":"kornrunner/packagist","owner":{"login":"kornrunner","id":725986,"avatar_url":"https://avatars.githubusercontent.com/u/725986?v=3","gravatar_id":"","url":"https://api.github.com/users/kornrunner","html_url":"https://github.com/kornrunner","followers_url":"https://api.github.com/users/kornrunner/followers","following_url":"https://api.github.com/users/kornrunner/following{/other_user}","gists_url":"https://api.github.com/users/kornrunner/gists{/gist_id}","starred_url":"https://api.github.com/users/kornrunner/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kornrunner/subscriptions","organizations_url":"https://api.github.com/users/kornrunner/orgs","repos_url":"https://api.github.com/users/kornrunner/repos","events_url":"https://api.github.com/users/kornrunner/events{/privacy}","received_events_url":"https://api.github.com/users/kornrunner/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/kornrunner/packagist","description":"Package Repository Website","fork":true,"url":"https://api.github.com/repos/kornrunner/packagist","forks_url":"https://api.github.com/repos/kornrunner/packagist/forks","keys_url":"https://api.github.com/repos/kornrunner/packagist/keys{/key_id}","collaborators_url":"https://api.github.com/repos/kornrunner/packagist/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/kornrunner/packagist/teams","hooks_url":"https://api.github.com/repos/kornrunner/packagist/hooks","issue_events_url":"https://api.github.com/repos/kornrunner/packagist/issues/events{/number}","events_url":"https://api.github.com/repos/kornrunner/packagist/events","assignees_url":"https://api.github.com/repos/kornrunner/packagist/assignees{/user}","branches_url":"https://api.github.com/repos/kornrunner/packagist/branches{/branch}","tags_url":"https://api.github.com/repos/kornrunner/packagist/tags","blobs_url":"https://api.github.com/repos/kornrunner/packagist/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/kornrunner/packagist/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/kornrunner/packagist/git/refs{/sha}","trees_url":"https://api.github.com/repos/kornrunner/packagist/git/trees{/sha}","statuses_url":"https://api.github.com/repos/kornrunner/packagist/statuses/{sha}","languages_url":"https://api.github.com/repos/kornrunner/packagist/languages","stargazers_url":"https://api.github.com/repos/kornrunner/packagist/stargazers","contributors_url":"https://api.github.com/repos/kornrunner/packagist/contributors","subscribers_url":"https://api.github.com/repos/kornrunner/packagist/subscribers","subscription_url":"https://api.github.com/repos/kornrunner/packagist/subscription","commits_url":"https://api.github.com/repos/kornrunner/packagist/commits{/sha}","git_commits_url":"https://api.github.com/repos/kornrunner/packagist/git/commits{/sha}","comments_url":"https://api.github.com/repos/kornrunner/packagist/comments{/number}","issue_comment_url":"https://api.github.com/repos/kornrunner/packagist/issues/comments{/number}","contents_url":"https://api.github.com/repos/kornrunner/packagist/contents/{+path}","compare_url":"https://api.github.com/repos/kornrunner/packagist/compare/{base}...{head}","merges_url":"https://api.github.com/repos/kornrunner/packagist/merges","archive_url":"https://api.github.com/repos/kornrunner/packagist/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/kornrunner/packagist/downloads","issues_url":"https://api.github.com/repos/kornrunner/packagist/issues{/number}","pulls_url":"https://api.github.com/repos/kornrunner/packagist/pulls{/number}","milestones_url":"https://api.github.com/repos/kornrunner/packagist/milestones{/number}","notifications_url":"https://api.github.com/repos/kornrunner/packagist/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/kornrunner/packagist/labels{/name}","releases_url":"https://api.github.com/repos/kornrunner/packagist/releases{/id}","created_at":"2015-10-22T09:14:57Z","updated_at":"2015-10-22T09:14:58Z","pushed_at":"2015-10-22T16:16:23Z","git_url":"git://github.com/kornrunner/packagist.git","ssh_url":"git@github.com:kornrunner/packagist.git","clone_url":"https://github.com/kornrunner/packagist.git","svn_url":"https://github.com/kornrunner/packagist","homepage":"http://packagist.org/","size":8816,"stargazers_count":0,"watchers_count":0,"language":"PHP","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":"composer:master","ref":"master","sha":"28ea38e7c92cf81f7d3dbedbc04a6f583281912e","user":{"login":"composer","id":837015,"avatar_url":"https://avatars.githubusercontent.com/u/837015?v=3","gravatar_id":"","url":"https://api.github.com/users/composer","html_url":"https://github.com/composer","followers_url":"https://api.github.com/users/composer/followers","following_url":"https://api.github.com/users/composer/following{/other_user}","gists_url":"https://api.github.com/users/composer/gists{/gist_id}","starred_url":"https://api.github.com/users/composer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/composer/subscriptions","organizations_url":"https://api.github.com/users/composer/orgs","repos_url":"https://api.github.com/users/composer/repos","events_url":"https://api.github.com/users/composer/events{/privacy}","received_events_url":"https://api.github.com/users/composer/received_events","type":"Organization","site_admin":false},"repo":{"id":1872943,"name":"packagist","full_name":"composer/packagist","owner":{"login":"composer","id":837015,"avatar_url":"https://avatars.githubusercontent.com/u/837015?v=3","gravatar_id":"","url":"https://api.github.com/users/composer","html_url":"https://github.com/composer","followers_url":"https://api.github.com/users/composer/followers","following_url":"https://api.github.com/users/composer/following{/other_user}","gists_url":"https://api.github.com/users/composer/gists{/gist_id}","starred_url":"https://api.github.com/users/composer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/composer/subscriptions","organizations_url":"https://api.github.com/users/composer/orgs","repos_url":"https://api.github.com/users/composer/repos","events_url":"https://api.github.com/users/composer/events{/privacy}","received_events_url":"https://api.github.com/users/composer/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/composer/packagist","description":"Package Repository Website","fork":false,"url":"https://api.github.com/repos/composer/packagist","forks_url":"https://api.github.com/repos/composer/packagist/forks","keys_url":"https://api.github.com/repos/composer/packagist/keys{/key_id}","collaborators_url":"https://api.github.com/repos/composer/packagist/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/composer/packagist/teams","hooks_url":"https://api.github.com/repos/composer/packagist/hooks","issue_events_url":"https://api.github.com/repos/composer/packagist/issues/events{/number}","events_url":"https://api.github.com/repos/composer/packagist/events","assignees_url":"https://api.github.com/repos/composer/packagist/assignees{/user}","branches_url":"https://api.github.com/repos/composer/packagist/branches{/branch}","tags_url":"https://api.github.com/repos/composer/packagist/tags","blobs_url":"https://api.github.com/repos/composer/packagist/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/composer/packagist/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/composer/packagist/git/refs{/sha}","trees_url":"https://api.github.com/repos/composer/packagist/git/trees{/sha}","statuses_url":"https://api.github.com/repos/composer/packagist/statuses/{sha}","languages_url":"https://api.github.com/repos/composer/packagist/languages","stargazers_url":"https://api.github.com/repos/composer/packagist/stargazers","contributors_url":"https://api.github.com/repos/composer/packagist/contributors","subscribers_url":"https://api.github.com/repos/composer/packagist/subscribers","subscription_url":"https://api.github.com/repos/composer/packagist/subscription","commits_url":"https://api.github.com/repos/composer/packagist/commits{/sha}","git_commits_url":"https://api.github.com/repos/composer/packagist/git/commits{/sha}","comments_url":"https://api.github.com/repos/composer/packagist/comments{/number}","issue_comment_url":"https://api.github.com/repos/composer/packagist/issues/comments{/number}","contents_url":"https://api.github.com/repos/composer/packagist/contents/{+path}","compare_url":"https://api.github.com/repos/composer/packagist/compare/{base}...{head}","merges_url":"https://api.github.com/repos/composer/packagist/merges","archive_url":"https://api.github.com/repos/composer/packagist/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/composer/packagist/downloads","issues_url":"https://api.github.com/repos/composer/packagist/issues{/number}","pulls_url":"https://api.github.com/repos/composer/packagist/pulls{/number}","milestones_url":"https://api.github.com/repos/composer/packagist/milestones{/number}","notifications_url":"https://api.github.com/repos/composer/packagist/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/composer/packagist/labels{/name}","releases_url":"https://api.github.com/repos/composer/packagist/releases{/id}","created_at":"2011-06-09T20:50:15Z","updated_at":"2015-10-21T09:09:15Z","pushed_at":"2015-10-22T16:26:05Z","git_url":"git://github.com/composer/packagist.git","ssh_url":"git@github.com:composer/packagist.git","clone_url":"https://github.com/composer/packagist.git","svn_url":"https://github.com/composer/packagist","homepage":"http://packagist.org/","size":8816,"stargazers_count":567,"watchers_count":567,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":233,"mirror_url":null,"open_issues_count":61,"forks":233,"open_issues":61,"watchers":567,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/composer/packagist/pulls/599"},"html":{"href":"https://github.com/composer/packagist/pull/599"},"issue":{"href":"https://api.github.com/repos/composer/packagist/issues/599"},"comments":{"href":"https://api.github.com/repos/composer/packagist/issues/599/comments"},"review_comments":{"href":"https://api.github.com/repos/composer/packagist/pulls/599/comments"},"review_comment":{"href":"https://api.github.com/repos/composer/packagist/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/composer/packagist/pulls/599/commits"},"statuses":{"href":"https://api.github.com/repos/composer/packagist/statuses/a3d4425891342ecd26513dc6ccfc53d692d4eb48"}}}}