{"action":"created","comment":{"url":"https://api.github.com/repos/nodejs/node/pulls/comments/39492309","id":39492309,"diff_hunk":"@@ -0,0 +1,67 @@\n+// Copyright 2012 the V8 project authors. All rights reserved.\n+// Redistribution and use in source and binary forms, with or without\n+// modification, are permitted provided that the following conditions are\n+// met:\n+//\n+//     * Redistributions of source code must retain the above copyright\n+//       notice, this list of conditions and the following disclaimer.\n+//     * Redistributions in binary form must reproduce the above\n+//       copyright notice, this list of conditions and the following\n+//       disclaimer in the documentation and/or other materials provided\n+//       with the distribution.\n+//     * Neither the name of Google Inc. nor the names of its\n+//       contributors may be used to endorse or promote products derived\n+//       from this software without specific prior written permission.\n+//\n+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS\n+// \"AS IS\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT\n+// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR\n+// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT\n+// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,\n+// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT\n+// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,\n+// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY\n+// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT\n+// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE\n+// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n+\n+var cp = require('child_process');\n+var fs = require('fs');\n+var path = require('path');\n+\n+var toolsPath = path.join(__dirname, '..', '..', 'deps', 'v8', 'tools');\n+var scriptFiles = [\n+  path.join(__dirname, 'polyfill.js'),\n+  path.join(toolsPath, 'splaytree.js'),\n+  path.join(toolsPath, 'codemap.js'),\n+  path.join(toolsPath, 'csvparser.js'),\n+  path.join(toolsPath, 'consarray.js'),\n+  path.join(toolsPath, 'csvparser.js'),\n+  path.join(toolsPath, 'consarray.js'),\n+  path.join(toolsPath, 'profile.js'),\n+  path.join(toolsPath, 'profile_view.js'),\n+  path.join(toolsPath, 'logreader.js'),\n+  path.join(toolsPath, 'tickprocessor.js'),\n+  path.join(toolsPath, 'SourceMap.js'),\n+  path.join(toolsPath, 'tickprocessor-driver.js')];\n+\n+var tempScript = path.join(__dirname, 'tick-processor-input-script-$$');\n+var cat = cp.spawn('cat', scriptFiles);\n+cat.stdout.pipe(fs.createWriteStream(tempScript));\n+cat.stdout.on('end', function() {\n+  var tickArguments = [tempScript];\n+  if (process.platform === 'darwin') {\n+    tickArguments.push('--mac', '--nm=' + path.join(toolsPath, 'mac-nm'));\n+  } else if (process.platform === 'win32') {\n+    tickArguments.push('--windows');\n+  }\n+  tickArguments.push.apply(tickArguments, [].slice.call(process.argv, 2));","path":"tools/v8-prof/tick-processor.js","position":58,"original_position":58,"commit_id":"a4031c1afe33a193afb28ef7f2aafb8929aad505","original_commit_id":"a4031c1afe33a193afb28ef7f2aafb8929aad505","user":{"login":"bnoordhuis","id":275871,"avatar_url":"https://avatars.githubusercontent.com/u/275871?v=3","gravatar_id":"","url":"https://api.github.com/users/bnoordhuis","html_url":"https://github.com/bnoordhuis","followers_url":"https://api.github.com/users/bnoordhuis/followers","following_url":"https://api.github.com/users/bnoordhuis/following{/other_user}","gists_url":"https://api.github.com/users/bnoordhuis/gists{/gist_id}","starred_url":"https://api.github.com/users/bnoordhuis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bnoordhuis/subscriptions","organizations_url":"https://api.github.com/users/bnoordhuis/orgs","repos_url":"https://api.github.com/users/bnoordhuis/repos","events_url":"https://api.github.com/users/bnoordhuis/events{/privacy}","received_events_url":"https://api.github.com/users/bnoordhuis/received_events","type":"User","site_admin":false},"body":"`process.argv.slice(2)`- it's already an array.","created_at":"2015-09-15T09:50:06Z","updated_at":"2015-09-15T09:50:06Z","html_url":"https://github.com/nodejs/node/pull/2868#discussion_r39492309","pull_request_url":"https://api.github.com/repos/nodejs/node/pulls/2868","_links":{"self":{"href":"https://api.github.com/repos/nodejs/node/pulls/comments/39492309"},"html":{"href":"https://github.com/nodejs/node/pull/2868#discussion_r39492309"},"pull_request":{"href":"https://api.github.com/repos/nodejs/node/pulls/2868"}}},"pull_request":{"url":"https://api.github.com/repos/nodejs/node/pulls/2868","id":44990573,"html_url":"https://github.com/nodejs/node/pull/2868","diff_url":"https://github.com/nodejs/node/pull/2868.diff","patch_url":"https://github.com/nodejs/node/pull/2868.patch","issue_url":"https://api.github.com/repos/nodejs/node/issues/2868","number":2868,"state":"open","locked":false,"title":"tools: single, cross-platform tick processor","user":{"login":"matthewloring","id":1485909,"avatar_url":"https://avatars.githubusercontent.com/u/1485909?v=3","gravatar_id":"","url":"https://api.github.com/users/matthewloring","html_url":"https://github.com/matthewloring","followers_url":"https://api.github.com/users/matthewloring/followers","following_url":"https://api.github.com/users/matthewloring/following{/other_user}","gists_url":"https://api.github.com/users/matthewloring/gists{/gist_id}","starred_url":"https://api.github.com/users/matthewloring/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/matthewloring/subscriptions","organizations_url":"https://api.github.com/users/matthewloring/orgs","repos_url":"https://api.github.com/users/matthewloring/repos","events_url":"https://api.github.com/users/matthewloring/events{/privacy}","received_events_url":"https://api.github.com/users/matthewloring/received_events","type":"User","site_admin":false},"body":"Currently there are three separate tick processor scripts for\r\nmac, windows, and linux. These have been replaced with a single\r\nnode.js script to improve maintainability and remove the need\r\nto preserve parallel logic in these separate places.\r\n\r\n/cc @ofrobots @bnoordhuis @Fishrock123 @joaocgreis @Trott","created_at":"2015-09-14T22:47:56Z","updated_at":"2015-09-15T09:50:06Z","closed_at":null,"merged_at":null,"merge_commit_sha":"00164ea8d6dfa84002eb59f44c61999f46112d52","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/nodejs/node/pulls/2868/commits","review_comments_url":"https://api.github.com/repos/nodejs/node/pulls/2868/comments","review_comment_url":"https://api.github.com/repos/nodejs/node/pulls/comments{/number}","comments_url":"https://api.github.com/repos/nodejs/node/issues/2868/comments","statuses_url":"https://api.github.com/repos/nodejs/node/statuses/a4031c1afe33a193afb28ef7f2aafb8929aad505","head":{"label":"matthewloring:node-tick-processor","ref":"node-tick-processor","sha":"a4031c1afe33a193afb28ef7f2aafb8929aad505","user":{"login":"matthewloring","id":1485909,"avatar_url":"https://avatars.githubusercontent.com/u/1485909?v=3","gravatar_id":"","url":"https://api.github.com/users/matthewloring","html_url":"https://github.com/matthewloring","followers_url":"https://api.github.com/users/matthewloring/followers","following_url":"https://api.github.com/users/matthewloring/following{/other_user}","gists_url":"https://api.github.com/users/matthewloring/gists{/gist_id}","starred_url":"https://api.github.com/users/matthewloring/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/matthewloring/subscriptions","organizations_url":"https://api.github.com/users/matthewloring/orgs","repos_url":"https://api.github.com/users/matthewloring/repos","events_url":"https://api.github.com/users/matthewloring/events{/privacy}","received_events_url":"https://api.github.com/users/matthewloring/received_events","type":"User","site_admin":false},"repo":{"id":38261750,"name":"io.js","full_name":"matthewloring/io.js","owner":{"login":"matthewloring","id":1485909,"avatar_url":"https://avatars.githubusercontent.com/u/1485909?v=3","gravatar_id":"","url":"https://api.github.com/users/matthewloring","html_url":"https://github.com/matthewloring","followers_url":"https://api.github.com/users/matthewloring/followers","following_url":"https://api.github.com/users/matthewloring/following{/other_user}","gists_url":"https://api.github.com/users/matthewloring/gists{/gist_id}","starred_url":"https://api.github.com/users/matthewloring/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/matthewloring/subscriptions","organizations_url":"https://api.github.com/users/matthewloring/orgs","repos_url":"https://api.github.com/users/matthewloring/repos","events_url":"https://api.github.com/users/matthewloring/events{/privacy}","received_events_url":"https://api.github.com/users/matthewloring/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/matthewloring/io.js","description":"Future Node.js releases will be based on io.js","fork":true,"url":"https://api.github.com/repos/matthewloring/io.js","forks_url":"https://api.github.com/repos/matthewloring/io.js/forks","keys_url":"https://api.github.com/repos/matthewloring/io.js/keys{/key_id}","collaborators_url":"https://api.github.com/repos/matthewloring/io.js/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/matthewloring/io.js/teams","hooks_url":"https://api.github.com/repos/matthewloring/io.js/hooks","issue_events_url":"https://api.github.com/repos/matthewloring/io.js/issues/events{/number}","events_url":"https://api.github.com/repos/matthewloring/io.js/events","assignees_url":"https://api.github.com/repos/matthewloring/io.js/assignees{/user}","branches_url":"https://api.github.com/repos/matthewloring/io.js/branches{/branch}","tags_url":"https://api.github.com/repos/matthewloring/io.js/tags","blobs_url":"https://api.github.com/repos/matthewloring/io.js/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/matthewloring/io.js/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/matthewloring/io.js/git/refs{/sha}","trees_url":"https://api.github.com/repos/matthewloring/io.js/git/trees{/sha}","statuses_url":"https://api.github.com/repos/matthewloring/io.js/statuses/{sha}","languages_url":"https://api.github.com/repos/matthewloring/io.js/languages","stargazers_url":"https://api.github.com/repos/matthewloring/io.js/stargazers","contributors_url":"https://api.github.com/repos/matthewloring/io.js/contributors","subscribers_url":"https://api.github.com/repos/matthewloring/io.js/subscribers","subscription_url":"https://api.github.com/repos/matthewloring/io.js/subscription","commits_url":"https://api.github.com/repos/matthewloring/io.js/commits{/sha}","git_commits_url":"https://api.github.com/repos/matthewloring/io.js/git/commits{/sha}","comments_url":"https://api.github.com/repos/matthewloring/io.js/comments{/number}","issue_comment_url":"https://api.github.com/repos/matthewloring/io.js/issues/comments{/number}","contents_url":"https://api.github.com/repos/matthewloring/io.js/contents/{+path}","compare_url":"https://api.github.com/repos/matthewloring/io.js/compare/{base}...{head}","merges_url":"https://api.github.com/repos/matthewloring/io.js/merges","archive_url":"https://api.github.com/repos/matthewloring/io.js/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/matthewloring/io.js/downloads","issues_url":"https://api.github.com/repos/matthewloring/io.js/issues{/number}","pulls_url":"https://api.github.com/repos/matthewloring/io.js/pulls{/number}","milestones_url":"https://api.github.com/repos/matthewloring/io.js/milestones{/number}","notifications_url":"https://api.github.com/repos/matthewloring/io.js/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/matthewloring/io.js/labels{/name}","releases_url":"https://api.github.com/repos/matthewloring/io.js/releases{/id}","created_at":"2015-06-29T17:49:00Z","updated_at":"2015-06-29T17:49:05Z","pushed_at":"2015-09-14T22:43:09Z","git_url":"git://github.com/matthewloring/io.js.git","ssh_url":"git@github.com:matthewloring/io.js.git","clone_url":"https://github.com/matthewloring/io.js.git","svn_url":"https://github.com/matthewloring/io.js","homepage":"https://iojs.org","size":143480,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","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":"nodejs:master","ref":"master","sha":"b9813641dcfda60a1c0035cb385ef0cbbaf9577f","user":{"login":"nodejs","id":9950313,"avatar_url":"https://avatars.githubusercontent.com/u/9950313?v=3","gravatar_id":"","url":"https://api.github.com/users/nodejs","html_url":"https://github.com/nodejs","followers_url":"https://api.github.com/users/nodejs/followers","following_url":"https://api.github.com/users/nodejs/following{/other_user}","gists_url":"https://api.github.com/users/nodejs/gists{/gist_id}","starred_url":"https://api.github.com/users/nodejs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nodejs/subscriptions","organizations_url":"https://api.github.com/users/nodejs/orgs","repos_url":"https://api.github.com/users/nodejs/repos","events_url":"https://api.github.com/users/nodejs/events{/privacy}","received_events_url":"https://api.github.com/users/nodejs/received_events","type":"Organization","site_admin":false},"repo":{"id":27193779,"name":"node","full_name":"nodejs/node","owner":{"login":"nodejs","id":9950313,"avatar_url":"https://avatars.githubusercontent.com/u/9950313?v=3","gravatar_id":"","url":"https://api.github.com/users/nodejs","html_url":"https://github.com/nodejs","followers_url":"https://api.github.com/users/nodejs/followers","following_url":"https://api.github.com/users/nodejs/following{/other_user}","gists_url":"https://api.github.com/users/nodejs/gists{/gist_id}","starred_url":"https://api.github.com/users/nodejs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nodejs/subscriptions","organizations_url":"https://api.github.com/users/nodejs/orgs","repos_url":"https://api.github.com/users/nodejs/repos","events_url":"https://api.github.com/users/nodejs/events{/privacy}","received_events_url":"https://api.github.com/users/nodejs/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/nodejs/node","description":"✨Node.js  ✨","fork":false,"url":"https://api.github.com/repos/nodejs/node","forks_url":"https://api.github.com/repos/nodejs/node/forks","keys_url":"https://api.github.com/repos/nodejs/node/keys{/key_id}","collaborators_url":"https://api.github.com/repos/nodejs/node/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/nodejs/node/teams","hooks_url":"https://api.github.com/repos/nodejs/node/hooks","issue_events_url":"https://api.github.com/repos/nodejs/node/issues/events{/number}","events_url":"https://api.github.com/repos/nodejs/node/events","assignees_url":"https://api.github.com/repos/nodejs/node/assignees{/user}","branches_url":"https://api.github.com/repos/nodejs/node/branches{/branch}","tags_url":"https://api.github.com/repos/nodejs/node/tags","blobs_url":"https://api.github.com/repos/nodejs/node/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/nodejs/node/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/nodejs/node/git/refs{/sha}","trees_url":"https://api.github.com/repos/nodejs/node/git/trees{/sha}","statuses_url":"https://api.github.com/repos/nodejs/node/statuses/{sha}","languages_url":"https://api.github.com/repos/nodejs/node/languages","stargazers_url":"https://api.github.com/repos/nodejs/node/stargazers","contributors_url":"https://api.github.com/repos/nodejs/node/contributors","subscribers_url":"https://api.github.com/repos/nodejs/node/subscribers","subscription_url":"https://api.github.com/repos/nodejs/node/subscription","commits_url":"https://api.github.com/repos/nodejs/node/commits{/sha}","git_commits_url":"https://api.github.com/repos/nodejs/node/git/commits{/sha}","comments_url":"https://api.github.com/repos/nodejs/node/comments{/number}","issue_comment_url":"https://api.github.com/repos/nodejs/node/issues/comments{/number}","contents_url":"https://api.github.com/repos/nodejs/node/contents/{+path}","compare_url":"https://api.github.com/repos/nodejs/node/compare/{base}...{head}","merges_url":"https://api.github.com/repos/nodejs/node/merges","archive_url":"https://api.github.com/repos/nodejs/node/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/nodejs/node/downloads","issues_url":"https://api.github.com/repos/nodejs/node/issues{/number}","pulls_url":"https://api.github.com/repos/nodejs/node/pulls{/number}","milestones_url":"https://api.github.com/repos/nodejs/node/milestones{/number}","notifications_url":"https://api.github.com/repos/nodejs/node/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/nodejs/node/labels{/name}","releases_url":"https://api.github.com/repos/nodejs/node/releases{/id}","created_at":"2014-11-26T19:57:11Z","updated_at":"2015-09-15T09:24:07Z","pushed_at":"2015-09-15T09:14:58Z","git_url":"git://github.com/nodejs/node.git","ssh_url":"git@github.com:nodejs/node.git","clone_url":"https://github.com/nodejs/node.git","svn_url":"https://github.com/nodejs/node","homepage":"https://nodejs.org","size":331038,"stargazers_count":14908,"watchers_count":14908,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1284,"mirror_url":null,"open_issues_count":412,"forks":1284,"open_issues":412,"watchers":14908,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/nodejs/node/pulls/2868"},"html":{"href":"https://github.com/nodejs/node/pull/2868"},"issue":{"href":"https://api.github.com/repos/nodejs/node/issues/2868"},"comments":{"href":"https://api.github.com/repos/nodejs/node/issues/2868/comments"},"review_comments":{"href":"https://api.github.com/repos/nodejs/node/pulls/2868/comments"},"review_comment":{"href":"https://api.github.com/repos/nodejs/node/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/nodejs/node/pulls/2868/commits"},"statuses":{"href":"https://api.github.com/repos/nodejs/node/statuses/a4031c1afe33a193afb28ef7f2aafb8929aad505"}}}}