{"action":"created","comment":{"url":"https://api.github.com/repos/mozilla/mozregression/pulls/comments/30582125","id":30582125,"diff_hunk":"@@ -118,19 +115,48 @@ def parse_args():\n \n     bundle = subparsers.add_parser('bundle',\n                                    help='bundle the application (freeze)')\n+    if IS_WIN:\n+        default_python_path = 'C:\\\\Python27'\n+        bundle.add_argument('--nsis-path', dest='nsis_path',\n+                            default='C:\\\\NSIS',\n+                            help='your NSIS path on the'\n+                            ' system(default: %(default)r)')\n+    else:\n+        default_python_path = '/usr/lib/python2.7'\n+\n     bundle.add_argument('--python-path', dest='python_path',\n-                        default='C:\\\\Python27',\n+                        default=default_python_path,\n                         help='your python path on the'\n                         ' system(default: %(default)r)')\n-    bundle.add_argument('--nsis-path', dest='nsis_path',\n-                        default='C:\\\\NSIS',\n-                        help='your NSIS path on the'\n-                        ' system(default: %(default)r)')\n     bundle.set_defaults(func=do_bundle)\n \n     return parser.parse_args()\n \n \n+def call_cx_freeze(gui_path, moz_path, python_lib_path):\n+    args = []\n+    if IS_WIN:\n+        args.append('--icon=wininst/app_icon.ico')\n+        args.append('--base-name=Win32GUI')\n+        args.append('--include-path=%s;%s;%s\\site-packages;%s'\n+                    % (gui_path, moz_path, python_lib_path, python_lib_path))\n+        args.append('--target-name=mozregression-gui.exe')\n+    else:\n+        args.append('--include-path=\"%s:%s:%s:%s/dist-packages\"'\n+                    % (gui_path, moz_path, python_lib_path, python_lib_path))\n+        args.append('--target-name=mozregression-gui')\n+    args.append('--target-dir=dist')\n+    args.append('mozregui/main.py')\n+    if IS_WIN:\n+        python_dir = os.path.join(","path":"gui/build.py","position":89,"original_position":89,"commit_id":"2a0f05e35ecdf653df773f07db98fa59582e7e6a","original_commit_id":"2a0f05e35ecdf653df773f07db98fa59582e7e6a","user":{"login":"MikeLing","id":2166227,"avatar_url":"https://avatars.githubusercontent.com/u/2166227?v=3","gravatar_id":"","url":"https://api.github.com/users/MikeLing","html_url":"https://github.com/MikeLing","followers_url":"https://api.github.com/users/MikeLing/followers","following_url":"https://api.github.com/users/MikeLing/following{/other_user}","gists_url":"https://api.github.com/users/MikeLing/gists{/gist_id}","starred_url":"https://api.github.com/users/MikeLing/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MikeLing/subscriptions","organizations_url":"https://api.github.com/users/MikeLing/orgs","repos_url":"https://api.github.com/users/MikeLing/repos","events_url":"https://api.github.com/users/MikeLing/events{/privacy}","received_events_url":"https://api.github.com/users/MikeLing/received_events","type":"User","site_admin":false},"body":"Should I add all the arguments in args? For example, the '--include-path' under windows and Linux are different.  I think add two different --include-path at once may cause some problem.","created_at":"2015-05-19T09:20:44Z","updated_at":"2015-05-19T09:20:44Z","html_url":"https://github.com/mozilla/mozregression/pull/225#discussion_r30582125","pull_request_url":"https://api.github.com/repos/mozilla/mozregression/pulls/225","_links":{"self":{"href":"https://api.github.com/repos/mozilla/mozregression/pulls/comments/30582125"},"html":{"href":"https://github.com/mozilla/mozregression/pull/225#discussion_r30582125"},"pull_request":{"href":"https://api.github.com/repos/mozilla/mozregression/pulls/225"}}},"pull_request":{"url":"https://api.github.com/repos/mozilla/mozregression/pulls/225","id":35692373,"html_url":"https://github.com/mozilla/mozregression/pull/225","diff_url":"https://github.com/mozilla/mozregression/pull/225.diff","patch_url":"https://github.com/mozilla/mozregression/pull/225.patch","issue_url":"https://api.github.com/repos/mozilla/mozregression/issues/225","number":225,"state":"open","locked":false,"title":"Bug 1165566 - [gui] update build.py bundle command to make it works for linux","user":{"login":"MikeLing","id":2166227,"avatar_url":"https://avatars.githubusercontent.com/u/2166227?v=3","gravatar_id":"","url":"https://api.github.com/users/MikeLing","html_url":"https://github.com/MikeLing","followers_url":"https://api.github.com/users/MikeLing/followers","following_url":"https://api.github.com/users/MikeLing/following{/other_user}","gists_url":"https://api.github.com/users/MikeLing/gists{/gist_id}","starred_url":"https://api.github.com/users/MikeLing/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MikeLing/subscriptions","organizations_url":"https://api.github.com/users/MikeLing/orgs","repos_url":"https://api.github.com/users/MikeLing/repos","events_url":"https://api.github.com/users/MikeLing/events{/privacy}","received_events_url":"https://api.github.com/users/MikeLing/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-05-19T03:02:20Z","updated_at":"2015-05-19T09:20:44Z","closed_at":null,"merged_at":null,"merge_commit_sha":"4f73a615f029adceeeda662335d59fb4c79bc318","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/mozilla/mozregression/pulls/225/commits","review_comments_url":"https://api.github.com/repos/mozilla/mozregression/pulls/225/comments","review_comment_url":"https://api.github.com/repos/mozilla/mozregression/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mozilla/mozregression/issues/225/comments","statuses_url":"https://api.github.com/repos/mozilla/mozregression/statuses/2a0f05e35ecdf653df773f07db98fa59582e7e6a","head":{"label":"MikeLing:Bug-1165566","ref":"Bug-1165566","sha":"2a0f05e35ecdf653df773f07db98fa59582e7e6a","user":{"login":"MikeLing","id":2166227,"avatar_url":"https://avatars.githubusercontent.com/u/2166227?v=3","gravatar_id":"","url":"https://api.github.com/users/MikeLing","html_url":"https://github.com/MikeLing","followers_url":"https://api.github.com/users/MikeLing/followers","following_url":"https://api.github.com/users/MikeLing/following{/other_user}","gists_url":"https://api.github.com/users/MikeLing/gists{/gist_id}","starred_url":"https://api.github.com/users/MikeLing/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MikeLing/subscriptions","organizations_url":"https://api.github.com/users/MikeLing/orgs","repos_url":"https://api.github.com/users/MikeLing/repos","events_url":"https://api.github.com/users/MikeLing/events{/privacy}","received_events_url":"https://api.github.com/users/MikeLing/received_events","type":"User","site_admin":false},"repo":{"id":34359167,"name":"mozregression","full_name":"MikeLing/mozregression","owner":{"login":"MikeLing","id":2166227,"avatar_url":"https://avatars.githubusercontent.com/u/2166227?v=3","gravatar_id":"","url":"https://api.github.com/users/MikeLing","html_url":"https://github.com/MikeLing","followers_url":"https://api.github.com/users/MikeLing/followers","following_url":"https://api.github.com/users/MikeLing/following{/other_user}","gists_url":"https://api.github.com/users/MikeLing/gists{/gist_id}","starred_url":"https://api.github.com/users/MikeLing/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MikeLing/subscriptions","organizations_url":"https://api.github.com/users/MikeLing/orgs","repos_url":"https://api.github.com/users/MikeLing/repos","events_url":"https://api.github.com/users/MikeLing/events{/privacy}","received_events_url":"https://api.github.com/users/MikeLing/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/MikeLing/mozregression","description":"Regression range finder for Mozilla nightly builds","fork":true,"url":"https://api.github.com/repos/MikeLing/mozregression","forks_url":"https://api.github.com/repos/MikeLing/mozregression/forks","keys_url":"https://api.github.com/repos/MikeLing/mozregression/keys{/key_id}","collaborators_url":"https://api.github.com/repos/MikeLing/mozregression/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/MikeLing/mozregression/teams","hooks_url":"https://api.github.com/repos/MikeLing/mozregression/hooks","issue_events_url":"https://api.github.com/repos/MikeLing/mozregression/issues/events{/number}","events_url":"https://api.github.com/repos/MikeLing/mozregression/events","assignees_url":"https://api.github.com/repos/MikeLing/mozregression/assignees{/user}","branches_url":"https://api.github.com/repos/MikeLing/mozregression/branches{/branch}","tags_url":"https://api.github.com/repos/MikeLing/mozregression/tags","blobs_url":"https://api.github.com/repos/MikeLing/mozregression/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/MikeLing/mozregression/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/MikeLing/mozregression/git/refs{/sha}","trees_url":"https://api.github.com/repos/MikeLing/mozregression/git/trees{/sha}","statuses_url":"https://api.github.com/repos/MikeLing/mozregression/statuses/{sha}","languages_url":"https://api.github.com/repos/MikeLing/mozregression/languages","stargazers_url":"https://api.github.com/repos/MikeLing/mozregression/stargazers","contributors_url":"https://api.github.com/repos/MikeLing/mozregression/contributors","subscribers_url":"https://api.github.com/repos/MikeLing/mozregression/subscribers","subscription_url":"https://api.github.com/repos/MikeLing/mozregression/subscription","commits_url":"https://api.github.com/repos/MikeLing/mozregression/commits{/sha}","git_commits_url":"https://api.github.com/repos/MikeLing/mozregression/git/commits{/sha}","comments_url":"https://api.github.com/repos/MikeLing/mozregression/comments{/number}","issue_comment_url":"https://api.github.com/repos/MikeLing/mozregression/issues/comments{/number}","contents_url":"https://api.github.com/repos/MikeLing/mozregression/contents/{+path}","compare_url":"https://api.github.com/repos/MikeLing/mozregression/compare/{base}...{head}","merges_url":"https://api.github.com/repos/MikeLing/mozregression/merges","archive_url":"https://api.github.com/repos/MikeLing/mozregression/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/MikeLing/mozregression/downloads","issues_url":"https://api.github.com/repos/MikeLing/mozregression/issues{/number}","pulls_url":"https://api.github.com/repos/MikeLing/mozregression/pulls{/number}","milestones_url":"https://api.github.com/repos/MikeLing/mozregression/milestones{/number}","notifications_url":"https://api.github.com/repos/MikeLing/mozregression/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/MikeLing/mozregression/labels{/name}","releases_url":"https://api.github.com/repos/MikeLing/mozregression/releases{/id}","created_at":"2015-04-22T00:19:20Z","updated_at":"2015-04-22T00:19:21Z","pushed_at":"2015-05-19T08:28:14Z","git_url":"git://github.com/MikeLing/mozregression.git","ssh_url":"git@github.com:MikeLing/mozregression.git","clone_url":"https://github.com/MikeLing/mozregression.git","svn_url":"https://github.com/MikeLing/mozregression","homepage":"http://mozilla.github.com/mozregression","size":1420,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"mozilla:master","ref":"master","sha":"341f93de625be9b6e794a12aae7c5461af97e024","user":{"login":"mozilla","id":131524,"avatar_url":"https://avatars.githubusercontent.com/u/131524?v=3","gravatar_id":"","url":"https://api.github.com/users/mozilla","html_url":"https://github.com/mozilla","followers_url":"https://api.github.com/users/mozilla/followers","following_url":"https://api.github.com/users/mozilla/following{/other_user}","gists_url":"https://api.github.com/users/mozilla/gists{/gist_id}","starred_url":"https://api.github.com/users/mozilla/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mozilla/subscriptions","organizations_url":"https://api.github.com/users/mozilla/orgs","repos_url":"https://api.github.com/users/mozilla/repos","events_url":"https://api.github.com/users/mozilla/events{/privacy}","received_events_url":"https://api.github.com/users/mozilla/received_events","type":"Organization","site_admin":false},"repo":{"id":512679,"name":"mozregression","full_name":"mozilla/mozregression","owner":{"login":"mozilla","id":131524,"avatar_url":"https://avatars.githubusercontent.com/u/131524?v=3","gravatar_id":"","url":"https://api.github.com/users/mozilla","html_url":"https://github.com/mozilla","followers_url":"https://api.github.com/users/mozilla/followers","following_url":"https://api.github.com/users/mozilla/following{/other_user}","gists_url":"https://api.github.com/users/mozilla/gists{/gist_id}","starred_url":"https://api.github.com/users/mozilla/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mozilla/subscriptions","organizations_url":"https://api.github.com/users/mozilla/orgs","repos_url":"https://api.github.com/users/mozilla/repos","events_url":"https://api.github.com/users/mozilla/events{/privacy}","received_events_url":"https://api.github.com/users/mozilla/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mozilla/mozregression","description":"Regression range finder for Mozilla nightly builds","fork":false,"url":"https://api.github.com/repos/mozilla/mozregression","forks_url":"https://api.github.com/repos/mozilla/mozregression/forks","keys_url":"https://api.github.com/repos/mozilla/mozregression/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mozilla/mozregression/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mozilla/mozregression/teams","hooks_url":"https://api.github.com/repos/mozilla/mozregression/hooks","issue_events_url":"https://api.github.com/repos/mozilla/mozregression/issues/events{/number}","events_url":"https://api.github.com/repos/mozilla/mozregression/events","assignees_url":"https://api.github.com/repos/mozilla/mozregression/assignees{/user}","branches_url":"https://api.github.com/repos/mozilla/mozregression/branches{/branch}","tags_url":"https://api.github.com/repos/mozilla/mozregression/tags","blobs_url":"https://api.github.com/repos/mozilla/mozregression/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mozilla/mozregression/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mozilla/mozregression/git/refs{/sha}","trees_url":"https://api.github.com/repos/mozilla/mozregression/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mozilla/mozregression/statuses/{sha}","languages_url":"https://api.github.com/repos/mozilla/mozregression/languages","stargazers_url":"https://api.github.com/repos/mozilla/mozregression/stargazers","contributors_url":"https://api.github.com/repos/mozilla/mozregression/contributors","subscribers_url":"https://api.github.com/repos/mozilla/mozregression/subscribers","subscription_url":"https://api.github.com/repos/mozilla/mozregression/subscription","commits_url":"https://api.github.com/repos/mozilla/mozregression/commits{/sha}","git_commits_url":"https://api.github.com/repos/mozilla/mozregression/git/commits{/sha}","comments_url":"https://api.github.com/repos/mozilla/mozregression/comments{/number}","issue_comment_url":"https://api.github.com/repos/mozilla/mozregression/issues/comments{/number}","contents_url":"https://api.github.com/repos/mozilla/mozregression/contents/{+path}","compare_url":"https://api.github.com/repos/mozilla/mozregression/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mozilla/mozregression/merges","archive_url":"https://api.github.com/repos/mozilla/mozregression/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mozilla/mozregression/downloads","issues_url":"https://api.github.com/repos/mozilla/mozregression/issues{/number}","pulls_url":"https://api.github.com/repos/mozilla/mozregression/pulls{/number}","milestones_url":"https://api.github.com/repos/mozilla/mozregression/milestones{/number}","notifications_url":"https://api.github.com/repos/mozilla/mozregression/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mozilla/mozregression/labels{/name}","releases_url":"https://api.github.com/repos/mozilla/mozregression/releases{/id}","created_at":"2010-02-11T05:49:14Z","updated_at":"2015-05-15T15:12:10Z","pushed_at":"2015-05-19T08:28:14Z","git_url":"git://github.com/mozilla/mozregression.git","ssh_url":"git@github.com:mozilla/mozregression.git","clone_url":"https://github.com/mozilla/mozregression.git","svn_url":"https://github.com/mozilla/mozregression","homepage":"http://mozilla.github.com/mozregression","size":3390,"stargazers_count":44,"watchers_count":44,"language":"Python","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":44,"mirror_url":null,"open_issues_count":1,"forks":44,"open_issues":1,"watchers":44,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/mozilla/mozregression/pulls/225"},"html":{"href":"https://github.com/mozilla/mozregression/pull/225"},"issue":{"href":"https://api.github.com/repos/mozilla/mozregression/issues/225"},"comments":{"href":"https://api.github.com/repos/mozilla/mozregression/issues/225/comments"},"review_comments":{"href":"https://api.github.com/repos/mozilla/mozregression/pulls/225/comments"},"review_comment":{"href":"https://api.github.com/repos/mozilla/mozregression/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mozilla/mozregression/pulls/225/commits"},"statuses":{"href":"https://api.github.com/repos/mozilla/mozregression/statuses/2a0f05e35ecdf653df773f07db98fa59582e7e6a"}}}}