{"action":"created","comment":{"url":"https://api.github.com/repos/brave/brave-core/pulls/comments/184296669","pull_request_review_id":115461751,"id":184296669,"diff_hunk":"@@ -0,0 +1,103 @@\n+#!/usr/bin/env python\n+\n+# This Source Code Form is subject to the terms of the Mozilla Public\n+# License, v. 2.0. If a copy of the MPL was not distributed with this file,\n+# You can obtain one at http://mozilla.org/MPL/2.0/.\n+\n+#\n+# Xcode supports build variable substitutions and CPP; sadly, that doesn't work\n+# because:\n+#\n+# 1. Xcode wants to do the Info.plist work before it runs any build phases,\n+#    this means if we were to generate a .h file for INFOPLIST_PREFIX_HEADER\n+#    we'd have to put it in another target so it runs in time.\n+# 2. Xcode also doesn't check to see if the header being used as a prefix for\n+#    the Info.plist has changed.  So even if we updated it, it's only looking\n+#    at the modtime of the info.plist to see if that's changed.\n+#\n+# So, we work around all of this by making a script build phase that will run\n+# during the app build, and simply update the info.plist in place.  This way\n+# by the time the app target is done, the info.plist is correct.\n+#\n+\n+import optparse\n+import os\n+import plistlib\n+import re\n+import subprocess\n+import sys\n+import tempfile\n+\n+def _ConvertPlist(source_plist, output_plist, fmt):\n+  \"\"\"Convert |source_plist| to |fmt| and save as |output_plist|.\"\"\"\n+  return subprocess.call(\n+      ['plutil', '-convert', fmt, '-o', output_plist, source_plist])\n+\n+\n+def _RemoveKeys(plist, *keys):\n+  \"\"\"Removes a varargs of keys from the plist.\"\"\"\n+  for key in keys:\n+    try:\n+      del plist[key]\n+    except KeyError:\n+      pass\n+\n+\n+def Main(argv):\n+  parser = optparse.OptionParser('%prog [options]')\n+  parser.add_option('--plist', dest='plist_path', action='store',\n+      type='string', default=None, help='The path of the plist to tweak.')\n+  parser.add_option('--output', dest='plist_output', action='store',\n+      type='string', default=None, help='If specified, the path to output ' + \\\n+      'the tweaked plist, rather than overwriting the input.')\n+  parser.add_option('--brave_channel', dest='brave_channel', action='store',\n+      type='string', default=None, help='Channel (beta, dev, canary)')\n+  parser.add_option('--brave_feed_url', dest='brave_feed_url', action='store',\n+      type='string', default=None, help='Target url for update feed')\n+  parser.add_option('--brave_dsa_file', dest='brave_dsa_file', action='store',\n+      type='string', default=None, help='Public DSA file for update')\n+  parser.add_option('--format', choices=('binary1', 'xml1', 'json'),\n+      default='xml1', help='Format to use when writing property list '\n+          '(default: %(default)s)')\n+  (options, args) = parser.parse_args(argv)\n+\n+  if len(args) > 0:\n+    print >>sys.stderr, parser.get_usage()\n+    return 1\n+\n+  if not options.plist_path:\n+    print >>sys.stderr, 'No --plist specified.'\n+    return 1\n+\n+  # Read the plist into its parsed format. Convert the file to 'xml1' as\n+  # plistlib only supports that format in Python 2.7.\n+  with tempfile.NamedTemporaryFile() as temp_info_plist:\n+    retcode = _ConvertPlist(options.plist_path, temp_info_plist.name, 'xml1')\n+    if retcode != 0:\n+      return retcode\n+    plist = plistlib.readPlist(temp_info_plist.name)\n+\n+  output_path = options.plist_path\n+  if options.plist_output is not None:\n+    output_path = options.plist_output\n+\n+  if options.brave_channel:\n+    plist['KSChannelID'] = options.brave_channel\n+\n+  if options.brave_feed_url:\n+    plist['SUFeedURL'] = options.brave_feed_url\n+\n+  if options.brave_feed_url:\n+    plist['SUPublicDSAKeyFile'] = options.brave_dsa_file","path":"build/mac/tweak_info_plist.py","position":null,"original_position":91,"commit_id":"8a80cb04af253688e7d39091bb61e44916ae87ba","original_commit_id":"9e580dc068781a1090dce089cca0e8fe931d7bbc","user":{"login":"simonhong","id":6786187,"avatar_url":"https://avatars3.githubusercontent.com/u/6786187?v=4","gravatar_id":"","url":"https://api.github.com/users/simonhong","html_url":"https://github.com/simonhong","followers_url":"https://api.github.com/users/simonhong/followers","following_url":"https://api.github.com/users/simonhong/following{/other_user}","gists_url":"https://api.github.com/users/simonhong/gists{/gist_id}","starred_url":"https://api.github.com/users/simonhong/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/simonhong/subscriptions","organizations_url":"https://api.github.com/users/simonhong/orgs","repos_url":"https://api.github.com/users/simonhong/repos","events_url":"https://api.github.com/users/simonhong/events{/privacy}","received_events_url":"https://api.github.com/users/simonhong/received_events","type":"User","site_admin":false},"body":"Oops, it's typo.\r\nChanged to `brave_dsa_file`.\r\nThanks!","created_at":"2018-04-26T07:45:15Z","updated_at":"2018-04-26T07:45:16Z","html_url":"https://github.com/brave/brave-core/pull/91#discussion_r184296669","pull_request_url":"https://api.github.com/repos/brave/brave-core/pulls/91","author_association":"COLLABORATOR","_links":{"self":{"href":"https://api.github.com/repos/brave/brave-core/pulls/comments/184296669"},"html":{"href":"https://github.com/brave/brave-core/pull/91#discussion_r184296669"},"pull_request":{"href":"https://api.github.com/repos/brave/brave-core/pulls/91"}},"in_reply_to_id":184267352},"pull_request":{"url":"https://api.github.com/repos/brave/brave-core/pulls/91","id":181088466,"html_url":"https://github.com/brave/brave-core/pull/91","diff_url":"https://github.com/brave/brave-core/pull/91.diff","patch_url":"https://github.com/brave/brave-core/pull/91.patch","issue_url":"https://api.github.com/repos/brave/brave-core/issues/91","number":91,"state":"open","locked":false,"title":"Sparkle framework integration","user":{"login":"simonhong","id":6786187,"avatar_url":"https://avatars3.githubusercontent.com/u/6786187?v=4","gravatar_id":"","url":"https://api.github.com/users/simonhong","html_url":"https://github.com/simonhong","followers_url":"https://api.github.com/users/simonhong/followers","following_url":"https://api.github.com/users/simonhong/following{/other_user}","gists_url":"https://api.github.com/users/simonhong/gists{/gist_id}","starred_url":"https://api.github.com/users/simonhong/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/simonhong/subscriptions","organizations_url":"https://api.github.com/users/simonhong/orgs","repos_url":"https://api.github.com/users/simonhong/repos","events_url":"https://api.github.com/users/simonhong/events{/privacy}","received_events_url":"https://api.github.com/users/simonhong/received_events","type":"User","site_admin":false},"body":"Add initial sparkle framework integration.\r\nUpdate stuff is added to BraveAppController(AppController subclass).\r\n\r\nIssue: https://github.com/brave/brave-browser/issues/159\r\n## Submitter Checklist:\r\n\r\n- [x] Submitted a [ticket](https://github.com/brave/brave-browser/issues) for my issue if one did not already exist.\r\n- [x] Used Github [auto-closing keywords](https://help.github.com/articles/closing-issues-via-commit-messages/) in the commit message.\r\n- [ ] Added/updated tests for this change (for new code or code which already has tests).\r\n- [ ] Ran `git rebase -i` to squash commits (if needed).\r\n- [x] Tagged reviewers and labelled the pull request as needed.\r\n- [ ] Request a security/privacy review as needed.\r\n\r\n## Test Plan:\r\n\r\n\r\n## Reviewer Checklist:\r\n\r\n- [ ] New files have MPL-2.0 license header.\r\n- [ ] Request a security/privacy review as needed.\r\n- [ ] Adequate test coverage exists to prevent regressions\r\n","created_at":"2018-04-12T04:37:14Z","updated_at":"2018-04-26T07:45:16Z","closed_at":null,"merged_at":null,"merge_commit_sha":"8115bf2f71570efc44c2decba405af9a1addce76","assignee":{"login":"simonhong","id":6786187,"avatar_url":"https://avatars3.githubusercontent.com/u/6786187?v=4","gravatar_id":"","url":"https://api.github.com/users/simonhong","html_url":"https://github.com/simonhong","followers_url":"https://api.github.com/users/simonhong/followers","following_url":"https://api.github.com/users/simonhong/following{/other_user}","gists_url":"https://api.github.com/users/simonhong/gists{/gist_id}","starred_url":"https://api.github.com/users/simonhong/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/simonhong/subscriptions","organizations_url":"https://api.github.com/users/simonhong/orgs","repos_url":"https://api.github.com/users/simonhong/repos","events_url":"https://api.github.com/users/simonhong/events{/privacy}","received_events_url":"https://api.github.com/users/simonhong/received_events","type":"User","site_admin":false},"assignees":[{"login":"simonhong","id":6786187,"avatar_url":"https://avatars3.githubusercontent.com/u/6786187?v=4","gravatar_id":"","url":"https://api.github.com/users/simonhong","html_url":"https://github.com/simonhong","followers_url":"https://api.github.com/users/simonhong/followers","following_url":"https://api.github.com/users/simonhong/following{/other_user}","gists_url":"https://api.github.com/users/simonhong/gists{/gist_id}","starred_url":"https://api.github.com/users/simonhong/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/simonhong/subscriptions","organizations_url":"https://api.github.com/users/simonhong/orgs","repos_url":"https://api.github.com/users/simonhong/repos","events_url":"https://api.github.com/users/simonhong/events{/privacy}","received_events_url":"https://api.github.com/users/simonhong/received_events","type":"User","site_admin":false}],"requested_reviewers":[{"login":"bbondy","id":831718,"avatar_url":"https://avatars2.githubusercontent.com/u/831718?v=4","gravatar_id":"","url":"https://api.github.com/users/bbondy","html_url":"https://github.com/bbondy","followers_url":"https://api.github.com/users/bbondy/followers","following_url":"https://api.github.com/users/bbondy/following{/other_user}","gists_url":"https://api.github.com/users/bbondy/gists{/gist_id}","starred_url":"https://api.github.com/users/bbondy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bbondy/subscriptions","organizations_url":"https://api.github.com/users/bbondy/orgs","repos_url":"https://api.github.com/users/bbondy/repos","events_url":"https://api.github.com/users/bbondy/events{/privacy}","received_events_url":"https://api.github.com/users/bbondy/received_events","type":"User","site_admin":false}],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/brave/brave-core/pulls/91/commits","review_comments_url":"https://api.github.com/repos/brave/brave-core/pulls/91/comments","review_comment_url":"https://api.github.com/repos/brave/brave-core/pulls/comments{/number}","comments_url":"https://api.github.com/repos/brave/brave-core/issues/91/comments","statuses_url":"https://api.github.com/repos/brave/brave-core/statuses/8a80cb04af253688e7d39091bb61e44916ae87ba","head":{"label":"brave:sparkle_integration","ref":"sparkle_integration","sha":"8a80cb04af253688e7d39091bb61e44916ae87ba","user":{"login":"brave","id":12301619,"avatar_url":"https://avatars1.githubusercontent.com/u/12301619?v=4","gravatar_id":"","url":"https://api.github.com/users/brave","html_url":"https://github.com/brave","followers_url":"https://api.github.com/users/brave/followers","following_url":"https://api.github.com/users/brave/following{/other_user}","gists_url":"https://api.github.com/users/brave/gists{/gist_id}","starred_url":"https://api.github.com/users/brave/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/brave/subscriptions","organizations_url":"https://api.github.com/users/brave/orgs","repos_url":"https://api.github.com/users/brave/repos","events_url":"https://api.github.com/users/brave/events{/privacy}","received_events_url":"https://api.github.com/users/brave/received_events","type":"Organization","site_admin":false},"repo":{"id":110198384,"name":"brave-core","full_name":"brave/brave-core","owner":{"login":"brave","id":12301619,"avatar_url":"https://avatars1.githubusercontent.com/u/12301619?v=4","gravatar_id":"","url":"https://api.github.com/users/brave","html_url":"https://github.com/brave","followers_url":"https://api.github.com/users/brave/followers","following_url":"https://api.github.com/users/brave/following{/other_user}","gists_url":"https://api.github.com/users/brave/gists{/gist_id}","starred_url":"https://api.github.com/users/brave/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/brave/subscriptions","organizations_url":"https://api.github.com/users/brave/orgs","repos_url":"https://api.github.com/users/brave/repos","events_url":"https://api.github.com/users/brave/events{/privacy}","received_events_url":"https://api.github.com/users/brave/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/brave/brave-core","description":"New version of muon based on chromium and for all platforms","fork":false,"url":"https://api.github.com/repos/brave/brave-core","forks_url":"https://api.github.com/repos/brave/brave-core/forks","keys_url":"https://api.github.com/repos/brave/brave-core/keys{/key_id}","collaborators_url":"https://api.github.com/repos/brave/brave-core/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/brave/brave-core/teams","hooks_url":"https://api.github.com/repos/brave/brave-core/hooks","issue_events_url":"https://api.github.com/repos/brave/brave-core/issues/events{/number}","events_url":"https://api.github.com/repos/brave/brave-core/events","assignees_url":"https://api.github.com/repos/brave/brave-core/assignees{/user}","branches_url":"https://api.github.com/repos/brave/brave-core/branches{/branch}","tags_url":"https://api.github.com/repos/brave/brave-core/tags","blobs_url":"https://api.github.com/repos/brave/brave-core/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/brave/brave-core/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/brave/brave-core/git/refs{/sha}","trees_url":"https://api.github.com/repos/brave/brave-core/git/trees{/sha}","statuses_url":"https://api.github.com/repos/brave/brave-core/statuses/{sha}","languages_url":"https://api.github.com/repos/brave/brave-core/languages","stargazers_url":"https://api.github.com/repos/brave/brave-core/stargazers","contributors_url":"https://api.github.com/repos/brave/brave-core/contributors","subscribers_url":"https://api.github.com/repos/brave/brave-core/subscribers","subscription_url":"https://api.github.com/repos/brave/brave-core/subscription","commits_url":"https://api.github.com/repos/brave/brave-core/commits{/sha}","git_commits_url":"https://api.github.com/repos/brave/brave-core/git/commits{/sha}","comments_url":"https://api.github.com/repos/brave/brave-core/comments{/number}","issue_comment_url":"https://api.github.com/repos/brave/brave-core/issues/comments{/number}","contents_url":"https://api.github.com/repos/brave/brave-core/contents/{+path}","compare_url":"https://api.github.com/repos/brave/brave-core/compare/{base}...{head}","merges_url":"https://api.github.com/repos/brave/brave-core/merges","archive_url":"https://api.github.com/repos/brave/brave-core/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/brave/brave-core/downloads","issues_url":"https://api.github.com/repos/brave/brave-core/issues{/number}","pulls_url":"https://api.github.com/repos/brave/brave-core/pulls{/number}","milestones_url":"https://api.github.com/repos/brave/brave-core/milestones{/number}","notifications_url":"https://api.github.com/repos/brave/brave-core/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/brave/brave-core/labels{/name}","releases_url":"https://api.github.com/repos/brave/brave-core/releases{/id}","deployments_url":"https://api.github.com/repos/brave/brave-core/deployments","created_at":"2017-11-10T03:33:30Z","updated_at":"2018-04-25T22:00:20Z","pushed_at":"2018-04-26T07:43:49Z","git_url":"git://github.com/brave/brave-core.git","ssh_url":"git@github.com:brave/brave-core.git","clone_url":"https://github.com/brave/brave-core.git","svn_url":"https://github.com/brave/brave-core","homepage":null,"size":8718,"stargazers_count":42,"watchers_count":42,"language":"C++","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":5,"mirror_url":null,"archived":false,"open_issues_count":4,"license":{"key":"other","name":"Other","spdx_id":null,"url":null},"forks":5,"open_issues":4,"watchers":42,"default_branch":"master"}},"base":{"label":"brave:master","ref":"master","sha":"3a0a4315e607fd4bdb6e3c6b7e035e632d158cc1","user":{"login":"brave","id":12301619,"avatar_url":"https://avatars1.githubusercontent.com/u/12301619?v=4","gravatar_id":"","url":"https://api.github.com/users/brave","html_url":"https://github.com/brave","followers_url":"https://api.github.com/users/brave/followers","following_url":"https://api.github.com/users/brave/following{/other_user}","gists_url":"https://api.github.com/users/brave/gists{/gist_id}","starred_url":"https://api.github.com/users/brave/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/brave/subscriptions","organizations_url":"https://api.github.com/users/brave/orgs","repos_url":"https://api.github.com/users/brave/repos","events_url":"https://api.github.com/users/brave/events{/privacy}","received_events_url":"https://api.github.com/users/brave/received_events","type":"Organization","site_admin":false},"repo":{"id":110198384,"name":"brave-core","full_name":"brave/brave-core","owner":{"login":"brave","id":12301619,"avatar_url":"https://avatars1.githubusercontent.com/u/12301619?v=4","gravatar_id":"","url":"https://api.github.com/users/brave","html_url":"https://github.com/brave","followers_url":"https://api.github.com/users/brave/followers","following_url":"https://api.github.com/users/brave/following{/other_user}","gists_url":"https://api.github.com/users/brave/gists{/gist_id}","starred_url":"https://api.github.com/users/brave/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/brave/subscriptions","organizations_url":"https://api.github.com/users/brave/orgs","repos_url":"https://api.github.com/users/brave/repos","events_url":"https://api.github.com/users/brave/events{/privacy}","received_events_url":"https://api.github.com/users/brave/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/brave/brave-core","description":"New version of muon based on chromium and for all platforms","fork":false,"url":"https://api.github.com/repos/brave/brave-core","forks_url":"https://api.github.com/repos/brave/brave-core/forks","keys_url":"https://api.github.com/repos/brave/brave-core/keys{/key_id}","collaborators_url":"https://api.github.com/repos/brave/brave-core/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/brave/brave-core/teams","hooks_url":"https://api.github.com/repos/brave/brave-core/hooks","issue_events_url":"https://api.github.com/repos/brave/brave-core/issues/events{/number}","events_url":"https://api.github.com/repos/brave/brave-core/events","assignees_url":"https://api.github.com/repos/brave/brave-core/assignees{/user}","branches_url":"https://api.github.com/repos/brave/brave-core/branches{/branch}","tags_url":"https://api.github.com/repos/brave/brave-core/tags","blobs_url":"https://api.github.com/repos/brave/brave-core/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/brave/brave-core/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/brave/brave-core/git/refs{/sha}","trees_url":"https://api.github.com/repos/brave/brave-core/git/trees{/sha}","statuses_url":"https://api.github.com/repos/brave/brave-core/statuses/{sha}","languages_url":"https://api.github.com/repos/brave/brave-core/languages","stargazers_url":"https://api.github.com/repos/brave/brave-core/stargazers","contributors_url":"https://api.github.com/repos/brave/brave-core/contributors","subscribers_url":"https://api.github.com/repos/brave/brave-core/subscribers","subscription_url":"https://api.github.com/repos/brave/brave-core/subscription","commits_url":"https://api.github.com/repos/brave/brave-core/commits{/sha}","git_commits_url":"https://api.github.com/repos/brave/brave-core/git/commits{/sha}","comments_url":"https://api.github.com/repos/brave/brave-core/comments{/number}","issue_comment_url":"https://api.github.com/repos/brave/brave-core/issues/comments{/number}","contents_url":"https://api.github.com/repos/brave/brave-core/contents/{+path}","compare_url":"https://api.github.com/repos/brave/brave-core/compare/{base}...{head}","merges_url":"https://api.github.com/repos/brave/brave-core/merges","archive_url":"https://api.github.com/repos/brave/brave-core/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/brave/brave-core/downloads","issues_url":"https://api.github.com/repos/brave/brave-core/issues{/number}","pulls_url":"https://api.github.com/repos/brave/brave-core/pulls{/number}","milestones_url":"https://api.github.com/repos/brave/brave-core/milestones{/number}","notifications_url":"https://api.github.com/repos/brave/brave-core/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/brave/brave-core/labels{/name}","releases_url":"https://api.github.com/repos/brave/brave-core/releases{/id}","deployments_url":"https://api.github.com/repos/brave/brave-core/deployments","created_at":"2017-11-10T03:33:30Z","updated_at":"2018-04-25T22:00:20Z","pushed_at":"2018-04-26T07:43:49Z","git_url":"git://github.com/brave/brave-core.git","ssh_url":"git@github.com:brave/brave-core.git","clone_url":"https://github.com/brave/brave-core.git","svn_url":"https://github.com/brave/brave-core","homepage":null,"size":8718,"stargazers_count":42,"watchers_count":42,"language":"C++","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":5,"mirror_url":null,"archived":false,"open_issues_count":4,"license":{"key":"other","name":"Other","spdx_id":null,"url":null},"forks":5,"open_issues":4,"watchers":42,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/brave/brave-core/pulls/91"},"html":{"href":"https://github.com/brave/brave-core/pull/91"},"issue":{"href":"https://api.github.com/repos/brave/brave-core/issues/91"},"comments":{"href":"https://api.github.com/repos/brave/brave-core/issues/91/comments"},"review_comments":{"href":"https://api.github.com/repos/brave/brave-core/pulls/91/comments"},"review_comment":{"href":"https://api.github.com/repos/brave/brave-core/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/brave/brave-core/pulls/91/commits"},"statuses":{"href":"https://api.github.com/repos/brave/brave-core/statuses/8a80cb04af253688e7d39091bb61e44916ae87ba"}},"author_association":"COLLABORATOR"}}
{"actor":{"display_login":"simonhong"}}