{"action":"created","comment":{"url":"https://api.github.com/repos/angular/angular.js/pulls/comments/67136783","id":67136783,"diff_hunk":"@@ -151,7 +151,9 @@ var getCdnVersion = function() {\n           var cdnResult = shell.exec('curl http://ajax.googleapis.com/ajax/libs/angularjs/' + version + '/angular.min.js ' +\n                     '--head --write-out \"%{http_code}\" -o /dev/null -silent',\n                                       {silent: true});\n-          if (cdnResult.code === 0) {\n+          // Ignore if Curl can't write the file (code 23), e.g. on Windows, as we still get\n+          // the needed output from --write-out\n+          if (cdnResult.code === 0 || cdnResult.code === 23) {\n             var statusCode = cdnResult.output.trim();","path":"lib/versions/version-info.js","position":8,"original_position":8,"commit_id":"c5f32914553e7b369ecc3cbb09e2bc55f5804a40","original_commit_id":"c5f32914553e7b369ecc3cbb09e2bc55f5804a40","user":{"login":"petebacondarwin","id":15655,"avatar_url":"https://avatars.githubusercontent.com/u/15655?v=3","gravatar_id":"","url":"https://api.github.com/users/petebacondarwin","html_url":"https://github.com/petebacondarwin","followers_url":"https://api.github.com/users/petebacondarwin/followers","following_url":"https://api.github.com/users/petebacondarwin/following{/other_user}","gists_url":"https://api.github.com/users/petebacondarwin/gists{/gist_id}","starred_url":"https://api.github.com/users/petebacondarwin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/petebacondarwin/subscriptions","organizations_url":"https://api.github.com/users/petebacondarwin/orgs","repos_url":"https://api.github.com/users/petebacondarwin/repos","events_url":"https://api.github.com/users/petebacondarwin/events{/privacy}","received_events_url":"https://api.github.com/users/petebacondarwin/received_events","type":"User","site_admin":false},"body":"Really we only care about whether requests to this URL are 404 or not, right?\r\n\r\nWhy don't we ditch the curl altogether and just use the `http` library?\r\n\r\nhttps://nodejs.org/dist/latest-v4.x/docs/api/http.html#http_http_request_options_callback","created_at":"2016-06-15T10:23:56Z","updated_at":"2016-06-15T10:23:56Z","html_url":"https://github.com/angular/angular.js/pull/14780#discussion_r67136783","pull_request_url":"https://api.github.com/repos/angular/angular.js/pulls/14780","_links":{"self":{"href":"https://api.github.com/repos/angular/angular.js/pulls/comments/67136783"},"html":{"href":"https://github.com/angular/angular.js/pull/14780#discussion_r67136783"},"pull_request":{"href":"https://api.github.com/repos/angular/angular.js/pulls/14780"}}},"pull_request":{"url":"https://api.github.com/repos/angular/angular.js/pulls/14780","id":73883401,"html_url":"https://github.com/angular/angular.js/pull/14780","diff_url":"https://github.com/angular/angular.js/pull/14780.diff","patch_url":"https://github.com/angular/angular.js/pull/14780.patch","issue_url":"https://api.github.com/repos/angular/angular.js/issues/14780","number":14780,"state":"open","locked":false,"title":"chore(version-info.js): ignore curl file write errors","user":{"login":"Narretz","id":1153097,"avatar_url":"https://avatars.githubusercontent.com/u/1153097?v=3","gravatar_id":"","url":"https://api.github.com/users/Narretz","html_url":"https://github.com/Narretz","followers_url":"https://api.github.com/users/Narretz/followers","following_url":"https://api.github.com/users/Narretz/following{/other_user}","gists_url":"https://api.github.com/users/Narretz/gists{/gist_id}","starred_url":"https://api.github.com/users/Narretz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Narretz/subscriptions","organizations_url":"https://api.github.com/users/Narretz/orgs","repos_url":"https://api.github.com/users/Narretz/repos","events_url":"https://api.github.com/users/Narretz/events{/privacy}","received_events_url":"https://api.github.com/users/Narretz/received_events","type":"User","site_admin":false},"body":"On Windows, curl can obviously not write to `dev/null`, and throws code 23, which prevents us from checking that the CDN server responded. However, we don't need the file anyway, we just need the status code, so we can ignore the file write error.\r\n\r\nThis needs to be tested on Linux / Mac however!","created_at":"2016-06-15T10:00:06Z","updated_at":"2016-06-15T10:23:56Z","closed_at":null,"merged_at":null,"merge_commit_sha":"73a0145b4a8582bfa0f5482efd42463037b3d0a5","assignee":{"login":"petebacondarwin","id":15655,"avatar_url":"https://avatars.githubusercontent.com/u/15655?v=3","gravatar_id":"","url":"https://api.github.com/users/petebacondarwin","html_url":"https://github.com/petebacondarwin","followers_url":"https://api.github.com/users/petebacondarwin/followers","following_url":"https://api.github.com/users/petebacondarwin/following{/other_user}","gists_url":"https://api.github.com/users/petebacondarwin/gists{/gist_id}","starred_url":"https://api.github.com/users/petebacondarwin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/petebacondarwin/subscriptions","organizations_url":"https://api.github.com/users/petebacondarwin/orgs","repos_url":"https://api.github.com/users/petebacondarwin/repos","events_url":"https://api.github.com/users/petebacondarwin/events{/privacy}","received_events_url":"https://api.github.com/users/petebacondarwin/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/angular/angular.js/milestones/90","html_url":"https://github.com/angular/angular.js/milestones/1.5.x","labels_url":"https://api.github.com/repos/angular/angular.js/milestones/90/labels","id":1025270,"number":90,"title":"1.5.x","description":"","creator":{"login":"petebacondarwin","id":15655,"avatar_url":"https://avatars.githubusercontent.com/u/15655?v=3","gravatar_id":"","url":"https://api.github.com/users/petebacondarwin","html_url":"https://github.com/petebacondarwin","followers_url":"https://api.github.com/users/petebacondarwin/followers","following_url":"https://api.github.com/users/petebacondarwin/following{/other_user}","gists_url":"https://api.github.com/users/petebacondarwin/gists{/gist_id}","starred_url":"https://api.github.com/users/petebacondarwin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/petebacondarwin/subscriptions","organizations_url":"https://api.github.com/users/petebacondarwin/orgs","repos_url":"https://api.github.com/users/petebacondarwin/repos","events_url":"https://api.github.com/users/petebacondarwin/events{/privacy}","received_events_url":"https://api.github.com/users/petebacondarwin/received_events","type":"User","site_admin":false},"open_issues":109,"closed_issues":149,"state":"open","created_at":"2015-03-17T12:15:49Z","updated_at":"2016-06-15T10:15:59Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/angular/angular.js/pulls/14780/commits","review_comments_url":"https://api.github.com/repos/angular/angular.js/pulls/14780/comments","review_comment_url":"https://api.github.com/repos/angular/angular.js/pulls/comments{/number}","comments_url":"https://api.github.com/repos/angular/angular.js/issues/14780/comments","statuses_url":"https://api.github.com/repos/angular/angular.js/statuses/c5f32914553e7b369ecc3cbb09e2bc55f5804a40","head":{"label":"Narretz:chore-cdn-win-fix","ref":"chore-cdn-win-fix","sha":"c5f32914553e7b369ecc3cbb09e2bc55f5804a40","user":{"login":"Narretz","id":1153097,"avatar_url":"https://avatars.githubusercontent.com/u/1153097?v=3","gravatar_id":"","url":"https://api.github.com/users/Narretz","html_url":"https://github.com/Narretz","followers_url":"https://api.github.com/users/Narretz/followers","following_url":"https://api.github.com/users/Narretz/following{/other_user}","gists_url":"https://api.github.com/users/Narretz/gists{/gist_id}","starred_url":"https://api.github.com/users/Narretz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Narretz/subscriptions","organizations_url":"https://api.github.com/users/Narretz/orgs","repos_url":"https://api.github.com/users/Narretz/repos","events_url":"https://api.github.com/users/Narretz/events{/privacy}","received_events_url":"https://api.github.com/users/Narretz/received_events","type":"User","site_admin":false},"repo":{"id":14773045,"name":"angular.js","full_name":"Narretz/angular.js","owner":{"login":"Narretz","id":1153097,"avatar_url":"https://avatars.githubusercontent.com/u/1153097?v=3","gravatar_id":"","url":"https://api.github.com/users/Narretz","html_url":"https://github.com/Narretz","followers_url":"https://api.github.com/users/Narretz/followers","following_url":"https://api.github.com/users/Narretz/following{/other_user}","gists_url":"https://api.github.com/users/Narretz/gists{/gist_id}","starred_url":"https://api.github.com/users/Narretz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Narretz/subscriptions","organizations_url":"https://api.github.com/users/Narretz/orgs","repos_url":"https://api.github.com/users/Narretz/repos","events_url":"https://api.github.com/users/Narretz/events{/privacy}","received_events_url":"https://api.github.com/users/Narretz/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Narretz/angular.js","description":"","fork":true,"url":"https://api.github.com/repos/Narretz/angular.js","forks_url":"https://api.github.com/repos/Narretz/angular.js/forks","keys_url":"https://api.github.com/repos/Narretz/angular.js/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Narretz/angular.js/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Narretz/angular.js/teams","hooks_url":"https://api.github.com/repos/Narretz/angular.js/hooks","issue_events_url":"https://api.github.com/repos/Narretz/angular.js/issues/events{/number}","events_url":"https://api.github.com/repos/Narretz/angular.js/events","assignees_url":"https://api.github.com/repos/Narretz/angular.js/assignees{/user}","branches_url":"https://api.github.com/repos/Narretz/angular.js/branches{/branch}","tags_url":"https://api.github.com/repos/Narretz/angular.js/tags","blobs_url":"https://api.github.com/repos/Narretz/angular.js/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Narretz/angular.js/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Narretz/angular.js/git/refs{/sha}","trees_url":"https://api.github.com/repos/Narretz/angular.js/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Narretz/angular.js/statuses/{sha}","languages_url":"https://api.github.com/repos/Narretz/angular.js/languages","stargazers_url":"https://api.github.com/repos/Narretz/angular.js/stargazers","contributors_url":"https://api.github.com/repos/Narretz/angular.js/contributors","subscribers_url":"https://api.github.com/repos/Narretz/angular.js/subscribers","subscription_url":"https://api.github.com/repos/Narretz/angular.js/subscription","commits_url":"https://api.github.com/repos/Narretz/angular.js/commits{/sha}","git_commits_url":"https://api.github.com/repos/Narretz/angular.js/git/commits{/sha}","comments_url":"https://api.github.com/repos/Narretz/angular.js/comments{/number}","issue_comment_url":"https://api.github.com/repos/Narretz/angular.js/issues/comments{/number}","contents_url":"https://api.github.com/repos/Narretz/angular.js/contents/{+path}","compare_url":"https://api.github.com/repos/Narretz/angular.js/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Narretz/angular.js/merges","archive_url":"https://api.github.com/repos/Narretz/angular.js/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Narretz/angular.js/downloads","issues_url":"https://api.github.com/repos/Narretz/angular.js/issues{/number}","pulls_url":"https://api.github.com/repos/Narretz/angular.js/pulls{/number}","milestones_url":"https://api.github.com/repos/Narretz/angular.js/milestones{/number}","notifications_url":"https://api.github.com/repos/Narretz/angular.js/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Narretz/angular.js/labels{/name}","releases_url":"https://api.github.com/repos/Narretz/angular.js/releases{/id}","deployments_url":"https://api.github.com/repos/Narretz/angular.js/deployments","created_at":"2013-11-28T09:39:41Z","updated_at":"2016-01-19T19:00:19Z","pushed_at":"2016-06-15T09:56:57Z","git_url":"git://github.com/Narretz/angular.js.git","ssh_url":"git@github.com:Narretz/angular.js.git","clone_url":"https://github.com/Narretz/angular.js.git","svn_url":"https://github.com/Narretz/angular.js","homepage":"http://angularjs.org","size":89172,"stargazers_count":1,"watchers_count":1,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":0,"forks":2,"open_issues":0,"watchers":1,"default_branch":"master"}},"base":{"label":"angular:master","ref":"master","sha":"857d78d17d2f7a1dc54855971f5f1961df7c7276","user":{"login":"angular","id":139426,"avatar_url":"https://avatars.githubusercontent.com/u/139426?v=3","gravatar_id":"","url":"https://api.github.com/users/angular","html_url":"https://github.com/angular","followers_url":"https://api.github.com/users/angular/followers","following_url":"https://api.github.com/users/angular/following{/other_user}","gists_url":"https://api.github.com/users/angular/gists{/gist_id}","starred_url":"https://api.github.com/users/angular/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/angular/subscriptions","organizations_url":"https://api.github.com/users/angular/orgs","repos_url":"https://api.github.com/users/angular/repos","events_url":"https://api.github.com/users/angular/events{/privacy}","received_events_url":"https://api.github.com/users/angular/received_events","type":"Organization","site_admin":false},"repo":{"id":460078,"name":"angular.js","full_name":"angular/angular.js","owner":{"login":"angular","id":139426,"avatar_url":"https://avatars.githubusercontent.com/u/139426?v=3","gravatar_id":"","url":"https://api.github.com/users/angular","html_url":"https://github.com/angular","followers_url":"https://api.github.com/users/angular/followers","following_url":"https://api.github.com/users/angular/following{/other_user}","gists_url":"https://api.github.com/users/angular/gists{/gist_id}","starred_url":"https://api.github.com/users/angular/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/angular/subscriptions","organizations_url":"https://api.github.com/users/angular/orgs","repos_url":"https://api.github.com/users/angular/repos","events_url":"https://api.github.com/users/angular/events{/privacy}","received_events_url":"https://api.github.com/users/angular/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/angular/angular.js","description":"HTML enhanced for web apps","fork":false,"url":"https://api.github.com/repos/angular/angular.js","forks_url":"https://api.github.com/repos/angular/angular.js/forks","keys_url":"https://api.github.com/repos/angular/angular.js/keys{/key_id}","collaborators_url":"https://api.github.com/repos/angular/angular.js/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/angular/angular.js/teams","hooks_url":"https://api.github.com/repos/angular/angular.js/hooks","issue_events_url":"https://api.github.com/repos/angular/angular.js/issues/events{/number}","events_url":"https://api.github.com/repos/angular/angular.js/events","assignees_url":"https://api.github.com/repos/angular/angular.js/assignees{/user}","branches_url":"https://api.github.com/repos/angular/angular.js/branches{/branch}","tags_url":"https://api.github.com/repos/angular/angular.js/tags","blobs_url":"https://api.github.com/repos/angular/angular.js/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/angular/angular.js/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/angular/angular.js/git/refs{/sha}","trees_url":"https://api.github.com/repos/angular/angular.js/git/trees{/sha}","statuses_url":"https://api.github.com/repos/angular/angular.js/statuses/{sha}","languages_url":"https://api.github.com/repos/angular/angular.js/languages","stargazers_url":"https://api.github.com/repos/angular/angular.js/stargazers","contributors_url":"https://api.github.com/repos/angular/angular.js/contributors","subscribers_url":"https://api.github.com/repos/angular/angular.js/subscribers","subscription_url":"https://api.github.com/repos/angular/angular.js/subscription","commits_url":"https://api.github.com/repos/angular/angular.js/commits{/sha}","git_commits_url":"https://api.github.com/repos/angular/angular.js/git/commits{/sha}","comments_url":"https://api.github.com/repos/angular/angular.js/comments{/number}","issue_comment_url":"https://api.github.com/repos/angular/angular.js/issues/comments{/number}","contents_url":"https://api.github.com/repos/angular/angular.js/contents/{+path}","compare_url":"https://api.github.com/repos/angular/angular.js/compare/{base}...{head}","merges_url":"https://api.github.com/repos/angular/angular.js/merges","archive_url":"https://api.github.com/repos/angular/angular.js/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/angular/angular.js/downloads","issues_url":"https://api.github.com/repos/angular/angular.js/issues{/number}","pulls_url":"https://api.github.com/repos/angular/angular.js/pulls{/number}","milestones_url":"https://api.github.com/repos/angular/angular.js/milestones{/number}","notifications_url":"https://api.github.com/repos/angular/angular.js/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/angular/angular.js/labels{/name}","releases_url":"https://api.github.com/repos/angular/angular.js/releases{/id}","deployments_url":"https://api.github.com/repos/angular/angular.js/deployments","created_at":"2010-01-06T00:34:37Z","updated_at":"2016-06-15T09:54:48Z","pushed_at":"2016-06-15T10:00:06Z","git_url":"git://github.com/angular/angular.js.git","ssh_url":"git@github.com:angular/angular.js.git","clone_url":"https://github.com/angular/angular.js.git","svn_url":"https://github.com/angular/angular.js","homepage":"http://angularjs.org","size":188637,"stargazers_count":49897,"watchers_count":49897,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":24112,"mirror_url":null,"open_issues_count":921,"forks":24112,"open_issues":921,"watchers":49897,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/angular/angular.js/pulls/14780"},"html":{"href":"https://github.com/angular/angular.js/pull/14780"},"issue":{"href":"https://api.github.com/repos/angular/angular.js/issues/14780"},"comments":{"href":"https://api.github.com/repos/angular/angular.js/issues/14780/comments"},"review_comments":{"href":"https://api.github.com/repos/angular/angular.js/pulls/14780/comments"},"review_comment":{"href":"https://api.github.com/repos/angular/angular.js/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/angular/angular.js/pulls/14780/commits"},"statuses":{"href":"https://api.github.com/repos/angular/angular.js/statuses/c5f32914553e7b369ecc3cbb09e2bc55f5804a40"}}}}
{"actor":{"display_login":"petebacondarwin"}}