{"action":"created","comment":{"url":"https://api.github.com/repos/GetFission/electron-fission/pulls/comments/147507789","pull_request_review_id":72619626,"id":147507789,"diff_hunk":"@@ -0,0 +1,66 @@\n+import { execSync } from 'child_process'\n+import * as os from 'os'\n+\n+export function validatePackageJson (packageJson : any) {\n+  const s3PublishInfo = packageJson.build.publish; \n+  console.log('Detected publish info', JSON.stringify(s3PublishInfo, null, ' '))\n+\n+  let validationErrors: string[] = []\n+  if (s3PublishInfo.provider !== \"s3\") {\n+    throw new Error('package.json:publish.provider key must have value \"s3\"')\n+  } else if (!s3PublishInfo.bucket) {\n+    throw new Error('package.json:publish.bucket key must have a bucket name')\n+  } else if (s3PublishInfo.path !== '${env.BRANCH}/${env.COMMIT}/${env.PLATFORM}') {\n+    throw new Error('package.json:publish.path key must be set to \"${env.BRANCH}/${env.COMMIT}/${env.PLATFORM}\"')\n+  }\n+}\n+\n+export function getAppPlatform(): string {\n+  if (process.env.APP_PLATFORM) {","path":"src/util.ts","position":19,"original_position":19,"commit_id":"8d512d2374a421e2352ed0e0ba4f1e1382909287","original_commit_id":"ef6cf7461bcd66a8203bb065ccb0bab5b56b12d9","user":{"login":"SimplyAhmazing","id":1294344,"avatar_url":"https://avatars0.githubusercontent.com/u/1294344?v=4","gravatar_id":"","url":"https://api.github.com/users/SimplyAhmazing","html_url":"https://github.com/SimplyAhmazing","followers_url":"https://api.github.com/users/SimplyAhmazing/followers","following_url":"https://api.github.com/users/SimplyAhmazing/following{/other_user}","gists_url":"https://api.github.com/users/SimplyAhmazing/gists{/gist_id}","starred_url":"https://api.github.com/users/SimplyAhmazing/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SimplyAhmazing/subscriptions","organizations_url":"https://api.github.com/users/SimplyAhmazing/orgs","repos_url":"https://api.github.com/users/SimplyAhmazing/repos","events_url":"https://api.github.com/users/SimplyAhmazing/events{/privacy}","received_events_url":"https://api.github.com/users/SimplyAhmazing/received_events","type":"User","site_admin":false},"body":"So that I can overwrite it for local testing. Also I was thinking it could be potentially useful for supporting other CI's if one knows what env vars are needed.","created_at":"2017-10-27T20:19:41Z","updated_at":"2017-10-27T20:19:41Z","html_url":"https://github.com/GetFission/electron-fission/pull/2#discussion_r147507789","pull_request_url":"https://api.github.com/repos/GetFission/electron-fission/pulls/2","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/GetFission/electron-fission/pulls/comments/147507789"},"html":{"href":"https://github.com/GetFission/electron-fission/pull/2#discussion_r147507789"},"pull_request":{"href":"https://api.github.com/repos/GetFission/electron-fission/pulls/2"}},"in_reply_to_id":147465137},"pull_request":{"url":"https://api.github.com/repos/GetFission/electron-fission/pulls/2","id":149226729,"html_url":"https://github.com/GetFission/electron-fission/pull/2","diff_url":"https://github.com/GetFission/electron-fission/pull/2.diff","patch_url":"https://github.com/GetFission/electron-fission/pull/2.patch","issue_url":"https://api.github.com/repos/GetFission/electron-fission/issues/2","number":2,"state":"open","locked":false,"title":"Upload artifact take2","user":{"login":"SimplyAhmazing","id":1294344,"avatar_url":"https://avatars0.githubusercontent.com/u/1294344?v=4","gravatar_id":"","url":"https://api.github.com/users/SimplyAhmazing","html_url":"https://github.com/SimplyAhmazing","followers_url":"https://api.github.com/users/SimplyAhmazing/followers","following_url":"https://api.github.com/users/SimplyAhmazing/following{/other_user}","gists_url":"https://api.github.com/users/SimplyAhmazing/gists{/gist_id}","starred_url":"https://api.github.com/users/SimplyAhmazing/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SimplyAhmazing/subscriptions","organizations_url":"https://api.github.com/users/SimplyAhmazing/orgs","repos_url":"https://api.github.com/users/SimplyAhmazing/repos","events_url":"https://api.github.com/users/SimplyAhmazing/events{/privacy}","received_events_url":"https://api.github.com/users/SimplyAhmazing/received_events","type":"User","site_admin":false},"body":"This PR,\r\n\r\n\r\n* sets up `yargs` for CLI\r\n* minor refactors for ping command\r\n* adds `init` command which takes a cli arg for bucket `--bucket sample-bucket`\r\n* adds `prep` command which will write `commit`, `branch`, and `platform` vars into a `electron-builder.env` file\r\n* adds tests for commands","created_at":"2017-10-27T16:00:44Z","updated_at":"2017-10-27T20:19:41Z","closed_at":null,"merged_at":null,"merge_commit_sha":"e4b8516e4b6cb4845c62ef0e85cf072aef83bfb9","assignee":null,"assignees":[],"requested_reviewers":[],"milestone":null,"commits_url":"https://api.github.com/repos/GetFission/electron-fission/pulls/2/commits","review_comments_url":"https://api.github.com/repos/GetFission/electron-fission/pulls/2/comments","review_comment_url":"https://api.github.com/repos/GetFission/electron-fission/pulls/comments{/number}","comments_url":"https://api.github.com/repos/GetFission/electron-fission/issues/2/comments","statuses_url":"https://api.github.com/repos/GetFission/electron-fission/statuses/8d512d2374a421e2352ed0e0ba4f1e1382909287","head":{"label":"GetFission:upload-artifact-take2","ref":"upload-artifact-take2","sha":"8d512d2374a421e2352ed0e0ba4f1e1382909287","user":{"login":"GetFission","id":33041096,"avatar_url":"https://avatars3.githubusercontent.com/u/33041096?v=4","gravatar_id":"","url":"https://api.github.com/users/GetFission","html_url":"https://github.com/GetFission","followers_url":"https://api.github.com/users/GetFission/followers","following_url":"https://api.github.com/users/GetFission/following{/other_user}","gists_url":"https://api.github.com/users/GetFission/gists{/gist_id}","starred_url":"https://api.github.com/users/GetFission/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GetFission/subscriptions","organizations_url":"https://api.github.com/users/GetFission/orgs","repos_url":"https://api.github.com/users/GetFission/repos","events_url":"https://api.github.com/users/GetFission/events{/privacy}","received_events_url":"https://api.github.com/users/GetFission/received_events","type":"Organization","site_admin":false},"repo":{"id":108333118,"name":"electron-fission","full_name":"GetFission/electron-fission","owner":{"login":"GetFission","id":33041096,"avatar_url":"https://avatars3.githubusercontent.com/u/33041096?v=4","gravatar_id":"","url":"https://api.github.com/users/GetFission","html_url":"https://github.com/GetFission","followers_url":"https://api.github.com/users/GetFission/followers","following_url":"https://api.github.com/users/GetFission/following{/other_user}","gists_url":"https://api.github.com/users/GetFission/gists{/gist_id}","starred_url":"https://api.github.com/users/GetFission/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GetFission/subscriptions","organizations_url":"https://api.github.com/users/GetFission/orgs","repos_url":"https://api.github.com/users/GetFission/repos","events_url":"https://api.github.com/users/GetFission/events{/privacy}","received_events_url":"https://api.github.com/users/GetFission/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/GetFission/electron-fission","description":null,"fork":false,"url":"https://api.github.com/repos/GetFission/electron-fission","forks_url":"https://api.github.com/repos/GetFission/electron-fission/forks","keys_url":"https://api.github.com/repos/GetFission/electron-fission/keys{/key_id}","collaborators_url":"https://api.github.com/repos/GetFission/electron-fission/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/GetFission/electron-fission/teams","hooks_url":"https://api.github.com/repos/GetFission/electron-fission/hooks","issue_events_url":"https://api.github.com/repos/GetFission/electron-fission/issues/events{/number}","events_url":"https://api.github.com/repos/GetFission/electron-fission/events","assignees_url":"https://api.github.com/repos/GetFission/electron-fission/assignees{/user}","branches_url":"https://api.github.com/repos/GetFission/electron-fission/branches{/branch}","tags_url":"https://api.github.com/repos/GetFission/electron-fission/tags","blobs_url":"https://api.github.com/repos/GetFission/electron-fission/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/GetFission/electron-fission/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/GetFission/electron-fission/git/refs{/sha}","trees_url":"https://api.github.com/repos/GetFission/electron-fission/git/trees{/sha}","statuses_url":"https://api.github.com/repos/GetFission/electron-fission/statuses/{sha}","languages_url":"https://api.github.com/repos/GetFission/electron-fission/languages","stargazers_url":"https://api.github.com/repos/GetFission/electron-fission/stargazers","contributors_url":"https://api.github.com/repos/GetFission/electron-fission/contributors","subscribers_url":"https://api.github.com/repos/GetFission/electron-fission/subscribers","subscription_url":"https://api.github.com/repos/GetFission/electron-fission/subscription","commits_url":"https://api.github.com/repos/GetFission/electron-fission/commits{/sha}","git_commits_url":"https://api.github.com/repos/GetFission/electron-fission/git/commits{/sha}","comments_url":"https://api.github.com/repos/GetFission/electron-fission/comments{/number}","issue_comment_url":"https://api.github.com/repos/GetFission/electron-fission/issues/comments{/number}","contents_url":"https://api.github.com/repos/GetFission/electron-fission/contents/{+path}","compare_url":"https://api.github.com/repos/GetFission/electron-fission/compare/{base}...{head}","merges_url":"https://api.github.com/repos/GetFission/electron-fission/merges","archive_url":"https://api.github.com/repos/GetFission/electron-fission/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/GetFission/electron-fission/downloads","issues_url":"https://api.github.com/repos/GetFission/electron-fission/issues{/number}","pulls_url":"https://api.github.com/repos/GetFission/electron-fission/pulls{/number}","milestones_url":"https://api.github.com/repos/GetFission/electron-fission/milestones{/number}","notifications_url":"https://api.github.com/repos/GetFission/electron-fission/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/GetFission/electron-fission/labels{/name}","releases_url":"https://api.github.com/repos/GetFission/electron-fission/releases{/id}","deployments_url":"https://api.github.com/repos/GetFission/electron-fission/deployments","created_at":"2017-10-25T22:29:27Z","updated_at":"2017-10-26T17:08:32Z","pushed_at":"2017-10-27T20:18:15Z","git_url":"git://github.com/GetFission/electron-fission.git","ssh_url":"git@github.com:GetFission/electron-fission.git","clone_url":"https://github.com/GetFission/electron-fission.git","svn_url":"https://github.com/GetFission/electron-fission","homepage":null,"size":115,"stargazers_count":2,"watchers_count":2,"language":"TypeScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":2,"default_branch":"master"}},"base":{"label":"GetFission:master","ref":"master","sha":"71fd89a8eb835a095c8e3120536ac36826de2993","user":{"login":"GetFission","id":33041096,"avatar_url":"https://avatars3.githubusercontent.com/u/33041096?v=4","gravatar_id":"","url":"https://api.github.com/users/GetFission","html_url":"https://github.com/GetFission","followers_url":"https://api.github.com/users/GetFission/followers","following_url":"https://api.github.com/users/GetFission/following{/other_user}","gists_url":"https://api.github.com/users/GetFission/gists{/gist_id}","starred_url":"https://api.github.com/users/GetFission/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GetFission/subscriptions","organizations_url":"https://api.github.com/users/GetFission/orgs","repos_url":"https://api.github.com/users/GetFission/repos","events_url":"https://api.github.com/users/GetFission/events{/privacy}","received_events_url":"https://api.github.com/users/GetFission/received_events","type":"Organization","site_admin":false},"repo":{"id":108333118,"name":"electron-fission","full_name":"GetFission/electron-fission","owner":{"login":"GetFission","id":33041096,"avatar_url":"https://avatars3.githubusercontent.com/u/33041096?v=4","gravatar_id":"","url":"https://api.github.com/users/GetFission","html_url":"https://github.com/GetFission","followers_url":"https://api.github.com/users/GetFission/followers","following_url":"https://api.github.com/users/GetFission/following{/other_user}","gists_url":"https://api.github.com/users/GetFission/gists{/gist_id}","starred_url":"https://api.github.com/users/GetFission/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GetFission/subscriptions","organizations_url":"https://api.github.com/users/GetFission/orgs","repos_url":"https://api.github.com/users/GetFission/repos","events_url":"https://api.github.com/users/GetFission/events{/privacy}","received_events_url":"https://api.github.com/users/GetFission/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/GetFission/electron-fission","description":null,"fork":false,"url":"https://api.github.com/repos/GetFission/electron-fission","forks_url":"https://api.github.com/repos/GetFission/electron-fission/forks","keys_url":"https://api.github.com/repos/GetFission/electron-fission/keys{/key_id}","collaborators_url":"https://api.github.com/repos/GetFission/electron-fission/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/GetFission/electron-fission/teams","hooks_url":"https://api.github.com/repos/GetFission/electron-fission/hooks","issue_events_url":"https://api.github.com/repos/GetFission/electron-fission/issues/events{/number}","events_url":"https://api.github.com/repos/GetFission/electron-fission/events","assignees_url":"https://api.github.com/repos/GetFission/electron-fission/assignees{/user}","branches_url":"https://api.github.com/repos/GetFission/electron-fission/branches{/branch}","tags_url":"https://api.github.com/repos/GetFission/electron-fission/tags","blobs_url":"https://api.github.com/repos/GetFission/electron-fission/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/GetFission/electron-fission/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/GetFission/electron-fission/git/refs{/sha}","trees_url":"https://api.github.com/repos/GetFission/electron-fission/git/trees{/sha}","statuses_url":"https://api.github.com/repos/GetFission/electron-fission/statuses/{sha}","languages_url":"https://api.github.com/repos/GetFission/electron-fission/languages","stargazers_url":"https://api.github.com/repos/GetFission/electron-fission/stargazers","contributors_url":"https://api.github.com/repos/GetFission/electron-fission/contributors","subscribers_url":"https://api.github.com/repos/GetFission/electron-fission/subscribers","subscription_url":"https://api.github.com/repos/GetFission/electron-fission/subscription","commits_url":"https://api.github.com/repos/GetFission/electron-fission/commits{/sha}","git_commits_url":"https://api.github.com/repos/GetFission/electron-fission/git/commits{/sha}","comments_url":"https://api.github.com/repos/GetFission/electron-fission/comments{/number}","issue_comment_url":"https://api.github.com/repos/GetFission/electron-fission/issues/comments{/number}","contents_url":"https://api.github.com/repos/GetFission/electron-fission/contents/{+path}","compare_url":"https://api.github.com/repos/GetFission/electron-fission/compare/{base}...{head}","merges_url":"https://api.github.com/repos/GetFission/electron-fission/merges","archive_url":"https://api.github.com/repos/GetFission/electron-fission/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/GetFission/electron-fission/downloads","issues_url":"https://api.github.com/repos/GetFission/electron-fission/issues{/number}","pulls_url":"https://api.github.com/repos/GetFission/electron-fission/pulls{/number}","milestones_url":"https://api.github.com/repos/GetFission/electron-fission/milestones{/number}","notifications_url":"https://api.github.com/repos/GetFission/electron-fission/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/GetFission/electron-fission/labels{/name}","releases_url":"https://api.github.com/repos/GetFission/electron-fission/releases{/id}","deployments_url":"https://api.github.com/repos/GetFission/electron-fission/deployments","created_at":"2017-10-25T22:29:27Z","updated_at":"2017-10-26T17:08:32Z","pushed_at":"2017-10-27T20:18:15Z","git_url":"git://github.com/GetFission/electron-fission.git","ssh_url":"git@github.com:GetFission/electron-fission.git","clone_url":"https://github.com/GetFission/electron-fission.git","svn_url":"https://github.com/GetFission/electron-fission","homepage":null,"size":115,"stargazers_count":2,"watchers_count":2,"language":"TypeScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":1,"forks":0,"open_issues":1,"watchers":2,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/GetFission/electron-fission/pulls/2"},"html":{"href":"https://github.com/GetFission/electron-fission/pull/2"},"issue":{"href":"https://api.github.com/repos/GetFission/electron-fission/issues/2"},"comments":{"href":"https://api.github.com/repos/GetFission/electron-fission/issues/2/comments"},"review_comments":{"href":"https://api.github.com/repos/GetFission/electron-fission/pulls/2/comments"},"review_comment":{"href":"https://api.github.com/repos/GetFission/electron-fission/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/GetFission/electron-fission/pulls/2/commits"},"statuses":{"href":"https://api.github.com/repos/GetFission/electron-fission/statuses/8d512d2374a421e2352ed0e0ba4f1e1382909287"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"SimplyAhmazing"}}