{"action":"created","comment":{"url":"https://api.github.com/repos/alexanderGugel/ied/pulls/comments/50527258","id":50527258,"diff_hunk":"@@ -120,6 +120,11 @@ function handleResolvedPkg (dir, pkg, cb) {\n       // package level.\n       fs.rename.bind(null, tmpDest, finalDest)\n     ], function (err) {\n+      // Include package.json's metadata.\n+      // `pkg` at this point just comes from the resolver, which only has\n+      // { name, version, uid, shasum, tarball }.\n+      pkg = assign({}, require(path.join(dir, pkg.uid, 'package.json')), pkg)","path":"lib/install.js","position":7,"original_position":7,"commit_id":"54f75d121eb41779776d9702464005571112cb49","original_commit_id":"af57467a1823525bd406bfc22dd26967c0ec097e","user":{"login":"just-boris","id":812240,"avatar_url":"https://avatars.githubusercontent.com/u/812240?v=3","gravatar_id":"","url":"https://api.github.com/users/just-boris","html_url":"https://github.com/just-boris","followers_url":"https://api.github.com/users/just-boris/followers","following_url":"https://api.github.com/users/just-boris/following{/other_user}","gists_url":"https://api.github.com/users/just-boris/gists{/gist_id}","starred_url":"https://api.github.com/users/just-boris/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/just-boris/subscriptions","organizations_url":"https://api.github.com/users/just-boris/orgs","repos_url":"https://api.github.com/users/just-boris/repos","events_url":"https://api.github.com/users/just-boris/events{/privacy}","received_events_url":"https://api.github.com/users/just-boris/received_events","type":"User","site_admin":false},"body":"I thought about another solution here.\r\n\r\nWe already have the `readPackage` function, here we can reuse its result.\r\n\r\nLook at [this](https://github.com/alexanderGugel/ied/blob/master/lib/install.js#L48), here the `pkg` argument has proper information, then we need to pass it up to callback:\r\n\r\n```js\r\nfunction installSubDeps (tmpDest, dir, pkg, cb) {\r\n  var subDependencies = assign({}, pkg.dependencies, pkg.peerDependencies)\r\n  async.forEachOf(subDependencies, function (version, name, cb) {\r\n    // ... cut ...\r\n  }, function(err, result) {\r\n      cb(err, result[0])\r\n  })\r\n}\r\n```\r\n\r\nThen we will have got package available [here](https://github.com/alexanderGugel/ied/blob/master/lib/install.js#L122) as the second argument.","created_at":"2016-01-22T11:28:49Z","updated_at":"2016-01-22T11:28:49Z","html_url":"https://github.com/alexanderGugel/ied/pull/68#discussion_r50527258","pull_request_url":"https://api.github.com/repos/alexanderGugel/ied/pulls/68","_links":{"self":{"href":"https://api.github.com/repos/alexanderGugel/ied/pulls/comments/50527258"},"html":{"href":"https://github.com/alexanderGugel/ied/pull/68#discussion_r50527258"},"pull_request":{"href":"https://api.github.com/repos/alexanderGugel/ied/pulls/68"}}},"pull_request":{"url":"https://api.github.com/repos/alexanderGugel/ied/pulls/68","id":56874767,"html_url":"https://github.com/alexanderGugel/ied/pull/68","diff_url":"https://github.com/alexanderGugel/ied/pull/68.diff","patch_url":"https://github.com/alexanderGugel/ied/pull/68.patch","issue_url":"https://api.github.com/repos/alexanderGugel/ied/issues/68","number":68,"state":"open","locked":false,"title":"Handle node_modules/.bin (#61)","user":{"login":"rstacruz","id":74385,"avatar_url":"https://avatars.githubusercontent.com/u/74385?v=3","gravatar_id":"","url":"https://api.github.com/users/rstacruz","html_url":"https://github.com/rstacruz","followers_url":"https://api.github.com/users/rstacruz/followers","following_url":"https://api.github.com/users/rstacruz/following{/other_user}","gists_url":"https://api.github.com/users/rstacruz/gists{/gist_id}","starred_url":"https://api.github.com/users/rstacruz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rstacruz/subscriptions","organizations_url":"https://api.github.com/users/rstacruz/orgs","repos_url":"https://api.github.com/users/rstacruz/repos","events_url":"https://api.github.com/users/rstacruz/events{/privacy}","received_events_url":"https://api.github.com/users/rstacruz/received_events","type":"User","site_admin":false},"body":"See #61.","created_at":"2016-01-22T11:11:08Z","updated_at":"2016-01-22T11:28:49Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d1809e64dc5418eb9ab8b59fee4fbf9fb8d0d8e8","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/alexanderGugel/ied/pulls/68/commits","review_comments_url":"https://api.github.com/repos/alexanderGugel/ied/pulls/68/comments","review_comment_url":"https://api.github.com/repos/alexanderGugel/ied/pulls/comments{/number}","comments_url":"https://api.github.com/repos/alexanderGugel/ied/issues/68/comments","statuses_url":"https://api.github.com/repos/alexanderGugel/ied/statuses/54f75d121eb41779776d9702464005571112cb49","head":{"label":"rstacruz:gh-61-bins","ref":"gh-61-bins","sha":"54f75d121eb41779776d9702464005571112cb49","user":{"login":"rstacruz","id":74385,"avatar_url":"https://avatars.githubusercontent.com/u/74385?v=3","gravatar_id":"","url":"https://api.github.com/users/rstacruz","html_url":"https://github.com/rstacruz","followers_url":"https://api.github.com/users/rstacruz/followers","following_url":"https://api.github.com/users/rstacruz/following{/other_user}","gists_url":"https://api.github.com/users/rstacruz/gists{/gist_id}","starred_url":"https://api.github.com/users/rstacruz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rstacruz/subscriptions","organizations_url":"https://api.github.com/users/rstacruz/orgs","repos_url":"https://api.github.com/users/rstacruz/repos","events_url":"https://api.github.com/users/rstacruz/events{/privacy}","received_events_url":"https://api.github.com/users/rstacruz/received_events","type":"User","site_admin":false},"repo":{"id":50173919,"name":"ied","full_name":"rstacruz/ied","owner":{"login":"rstacruz","id":74385,"avatar_url":"https://avatars.githubusercontent.com/u/74385?v=3","gravatar_id":"","url":"https://api.github.com/users/rstacruz","html_url":"https://github.com/rstacruz","followers_url":"https://api.github.com/users/rstacruz/followers","following_url":"https://api.github.com/users/rstacruz/following{/other_user}","gists_url":"https://api.github.com/users/rstacruz/gists{/gist_id}","starred_url":"https://api.github.com/users/rstacruz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rstacruz/subscriptions","organizations_url":"https://api.github.com/users/rstacruz/orgs","repos_url":"https://api.github.com/users/rstacruz/repos","events_url":"https://api.github.com/users/rstacruz/events{/privacy}","received_events_url":"https://api.github.com/users/rstacruz/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/rstacruz/ied","description":":package: Like npm, but faster - an alternative package manager for Node (WIP)","fork":true,"url":"https://api.github.com/repos/rstacruz/ied","forks_url":"https://api.github.com/repos/rstacruz/ied/forks","keys_url":"https://api.github.com/repos/rstacruz/ied/keys{/key_id}","collaborators_url":"https://api.github.com/repos/rstacruz/ied/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/rstacruz/ied/teams","hooks_url":"https://api.github.com/repos/rstacruz/ied/hooks","issue_events_url":"https://api.github.com/repos/rstacruz/ied/issues/events{/number}","events_url":"https://api.github.com/repos/rstacruz/ied/events","assignees_url":"https://api.github.com/repos/rstacruz/ied/assignees{/user}","branches_url":"https://api.github.com/repos/rstacruz/ied/branches{/branch}","tags_url":"https://api.github.com/repos/rstacruz/ied/tags","blobs_url":"https://api.github.com/repos/rstacruz/ied/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/rstacruz/ied/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/rstacruz/ied/git/refs{/sha}","trees_url":"https://api.github.com/repos/rstacruz/ied/git/trees{/sha}","statuses_url":"https://api.github.com/repos/rstacruz/ied/statuses/{sha}","languages_url":"https://api.github.com/repos/rstacruz/ied/languages","stargazers_url":"https://api.github.com/repos/rstacruz/ied/stargazers","contributors_url":"https://api.github.com/repos/rstacruz/ied/contributors","subscribers_url":"https://api.github.com/repos/rstacruz/ied/subscribers","subscription_url":"https://api.github.com/repos/rstacruz/ied/subscription","commits_url":"https://api.github.com/repos/rstacruz/ied/commits{/sha}","git_commits_url":"https://api.github.com/repos/rstacruz/ied/git/commits{/sha}","comments_url":"https://api.github.com/repos/rstacruz/ied/comments{/number}","issue_comment_url":"https://api.github.com/repos/rstacruz/ied/issues/comments{/number}","contents_url":"https://api.github.com/repos/rstacruz/ied/contents/{+path}","compare_url":"https://api.github.com/repos/rstacruz/ied/compare/{base}...{head}","merges_url":"https://api.github.com/repos/rstacruz/ied/merges","archive_url":"https://api.github.com/repos/rstacruz/ied/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/rstacruz/ied/downloads","issues_url":"https://api.github.com/repos/rstacruz/ied/issues{/number}","pulls_url":"https://api.github.com/repos/rstacruz/ied/pulls{/number}","milestones_url":"https://api.github.com/repos/rstacruz/ied/milestones{/number}","notifications_url":"https://api.github.com/repos/rstacruz/ied/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/rstacruz/ied/labels{/name}","releases_url":"https://api.github.com/repos/rstacruz/ied/releases{/id}","deployments_url":"https://api.github.com/repos/rstacruz/ied/deployments","created_at":"2016-01-22T10:16:04Z","updated_at":"2016-01-22T10:16:05Z","pushed_at":"2016-01-22T11:22:59Z","git_url":"git://github.com/rstacruz/ied.git","ssh_url":"git@github.com:rstacruz/ied.git","clone_url":"https://github.com/rstacruz/ied.git","svn_url":"https://github.com/rstacruz/ied","homepage":"http://alexandergugel.github.io/ied","size":3736,"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":"alexanderGugel:master","ref":"master","sha":"07135a7753b4982da91a1abc7c6c2bb62c99b9f1","user":{"login":"alexanderGugel","id":703628,"avatar_url":"https://avatars.githubusercontent.com/u/703628?v=3","gravatar_id":"","url":"https://api.github.com/users/alexanderGugel","html_url":"https://github.com/alexanderGugel","followers_url":"https://api.github.com/users/alexanderGugel/followers","following_url":"https://api.github.com/users/alexanderGugel/following{/other_user}","gists_url":"https://api.github.com/users/alexanderGugel/gists{/gist_id}","starred_url":"https://api.github.com/users/alexanderGugel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alexanderGugel/subscriptions","organizations_url":"https://api.github.com/users/alexanderGugel/orgs","repos_url":"https://api.github.com/users/alexanderGugel/repos","events_url":"https://api.github.com/users/alexanderGugel/events{/privacy}","received_events_url":"https://api.github.com/users/alexanderGugel/received_events","type":"User","site_admin":false},"repo":{"id":40329787,"name":"ied","full_name":"alexanderGugel/ied","owner":{"login":"alexanderGugel","id":703628,"avatar_url":"https://avatars.githubusercontent.com/u/703628?v=3","gravatar_id":"","url":"https://api.github.com/users/alexanderGugel","html_url":"https://github.com/alexanderGugel","followers_url":"https://api.github.com/users/alexanderGugel/followers","following_url":"https://api.github.com/users/alexanderGugel/following{/other_user}","gists_url":"https://api.github.com/users/alexanderGugel/gists{/gist_id}","starred_url":"https://api.github.com/users/alexanderGugel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alexanderGugel/subscriptions","organizations_url":"https://api.github.com/users/alexanderGugel/orgs","repos_url":"https://api.github.com/users/alexanderGugel/repos","events_url":"https://api.github.com/users/alexanderGugel/events{/privacy}","received_events_url":"https://api.github.com/users/alexanderGugel/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/alexanderGugel/ied","description":":package: Like npm, but faster - an alternative package manager for Node (WIP)","fork":false,"url":"https://api.github.com/repos/alexanderGugel/ied","forks_url":"https://api.github.com/repos/alexanderGugel/ied/forks","keys_url":"https://api.github.com/repos/alexanderGugel/ied/keys{/key_id}","collaborators_url":"https://api.github.com/repos/alexanderGugel/ied/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/alexanderGugel/ied/teams","hooks_url":"https://api.github.com/repos/alexanderGugel/ied/hooks","issue_events_url":"https://api.github.com/repos/alexanderGugel/ied/issues/events{/number}","events_url":"https://api.github.com/repos/alexanderGugel/ied/events","assignees_url":"https://api.github.com/repos/alexanderGugel/ied/assignees{/user}","branches_url":"https://api.github.com/repos/alexanderGugel/ied/branches{/branch}","tags_url":"https://api.github.com/repos/alexanderGugel/ied/tags","blobs_url":"https://api.github.com/repos/alexanderGugel/ied/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/alexanderGugel/ied/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/alexanderGugel/ied/git/refs{/sha}","trees_url":"https://api.github.com/repos/alexanderGugel/ied/git/trees{/sha}","statuses_url":"https://api.github.com/repos/alexanderGugel/ied/statuses/{sha}","languages_url":"https://api.github.com/repos/alexanderGugel/ied/languages","stargazers_url":"https://api.github.com/repos/alexanderGugel/ied/stargazers","contributors_url":"https://api.github.com/repos/alexanderGugel/ied/contributors","subscribers_url":"https://api.github.com/repos/alexanderGugel/ied/subscribers","subscription_url":"https://api.github.com/repos/alexanderGugel/ied/subscription","commits_url":"https://api.github.com/repos/alexanderGugel/ied/commits{/sha}","git_commits_url":"https://api.github.com/repos/alexanderGugel/ied/git/commits{/sha}","comments_url":"https://api.github.com/repos/alexanderGugel/ied/comments{/number}","issue_comment_url":"https://api.github.com/repos/alexanderGugel/ied/issues/comments{/number}","contents_url":"https://api.github.com/repos/alexanderGugel/ied/contents/{+path}","compare_url":"https://api.github.com/repos/alexanderGugel/ied/compare/{base}...{head}","merges_url":"https://api.github.com/repos/alexanderGugel/ied/merges","archive_url":"https://api.github.com/repos/alexanderGugel/ied/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/alexanderGugel/ied/downloads","issues_url":"https://api.github.com/repos/alexanderGugel/ied/issues{/number}","pulls_url":"https://api.github.com/repos/alexanderGugel/ied/pulls{/number}","milestones_url":"https://api.github.com/repos/alexanderGugel/ied/milestones{/number}","notifications_url":"https://api.github.com/repos/alexanderGugel/ied/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/alexanderGugel/ied/labels{/name}","releases_url":"https://api.github.com/repos/alexanderGugel/ied/releases{/id}","deployments_url":"https://api.github.com/repos/alexanderGugel/ied/deployments","created_at":"2015-08-06T22:30:30Z","updated_at":"2016-01-22T07:43:12Z","pushed_at":"2016-01-22T11:23:00Z","git_url":"git://github.com/alexanderGugel/ied.git","ssh_url":"git@github.com:alexanderGugel/ied.git","clone_url":"https://github.com/alexanderGugel/ied.git","svn_url":"https://github.com/alexanderGugel/ied","homepage":"http://alexandergugel.github.io/ied","size":3735,"stargazers_count":903,"watchers_count":903,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":30,"mirror_url":null,"open_issues_count":32,"forks":30,"open_issues":32,"watchers":903,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/alexanderGugel/ied/pulls/68"},"html":{"href":"https://github.com/alexanderGugel/ied/pull/68"},"issue":{"href":"https://api.github.com/repos/alexanderGugel/ied/issues/68"},"comments":{"href":"https://api.github.com/repos/alexanderGugel/ied/issues/68/comments"},"review_comments":{"href":"https://api.github.com/repos/alexanderGugel/ied/pulls/68/comments"},"review_comment":{"href":"https://api.github.com/repos/alexanderGugel/ied/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/alexanderGugel/ied/pulls/68/commits"},"statuses":{"href":"https://api.github.com/repos/alexanderGugel/ied/statuses/54f75d121eb41779776d9702464005571112cb49"}}}}