{"action":"created","comment":{"url":"https://api.github.com/repos/mixmaxhq/install-files/pulls/comments/101322693","pull_request_review_id":22047379,"id":101322693,"diff_hunk":"@@ -37,22 +37,20 @@ function installFiles(sourceDir, done) {\n   switch (npmv.majorVersion()) {\n     case '1':\n       console.log(\"[install-files]: WARNING: NPMv1 is not officially supported; unexpected results could occur. Consider upgrading to v2 or later\");\n+      /* falls through */\n     case '2':\n       source = sourceDir;\n       target = fileInstallingPackagePath && hostPackageDir(fileInstallingPackagePath);\n       break;\n     case null:\n-      console.log(\"[install-files]: WARNING: Could not determine NPM version\"); //Fall back to default\n+      console.log(\"[install-files]: WARNING: Could not determine NPM version\");\n+      /* falls through */\n     default:\n       source = path.join(fileInstallingPackagePath, 'node_modules', process.env.npm_package_name, sourceDir);\n-      target = fileInstallingPackagePath\n+      target = fileInstallingPackagePath;\n   }\n \n-  if (fileInstallingPackagePath.match(\".+\" + process.env.npm_package_name + \"$\")) {","path":"src/index.js","position":19,"original_position":19,"commit_id":"60a96146f85ccd55876a79487f983f9529aace93","original_commit_id":"60a96146f85ccd55876a79487f983f9529aace93","user":{"login":"GoGoCarl","id":1719249,"avatar_url":"https://avatars.githubusercontent.com/u/1719249?v=3","gravatar_id":"","url":"https://api.github.com/users/GoGoCarl","html_url":"https://github.com/GoGoCarl","followers_url":"https://api.github.com/users/GoGoCarl/followers","following_url":"https://api.github.com/users/GoGoCarl/following{/other_user}","gists_url":"https://api.github.com/users/GoGoCarl/gists{/gist_id}","starred_url":"https://api.github.com/users/GoGoCarl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GoGoCarl/subscriptions","organizations_url":"https://api.github.com/users/GoGoCarl/orgs","repos_url":"https://api.github.com/users/GoGoCarl/repos","events_url":"https://api.github.com/users/GoGoCarl/events{/privacy}","received_events_url":"https://api.github.com/users/GoGoCarl/received_events","type":"User","site_admin":false},"body":"@wearhere Actually, sorry about the previous comment.  I meant I would have wanted to check `target.match(...)`. My intentions here were to catch a case where the project that hosts the shared files runs `npm install`.  In this case, the process was running against itself, which was not ideal (but in thinking about it now, in some scenarios, this could be necessary).  I would say a better cross-version solution here would be to check to see if the source and the target package names are the same, and reject if that is the case. Thoughts?","created_at":"2017-02-15T16:41:43Z","updated_at":"2017-02-15T16:41:43Z","html_url":"https://github.com/mixmaxhq/install-files/pull/6#discussion_r101322693","pull_request_url":"https://api.github.com/repos/mixmaxhq/install-files/pulls/6","_links":{"self":{"href":"https://api.github.com/repos/mixmaxhq/install-files/pulls/comments/101322693"},"html":{"href":"https://github.com/mixmaxhq/install-files/pull/6#discussion_r101322693"},"pull_request":{"href":"https://api.github.com/repos/mixmaxhq/install-files/pulls/6"}}},"pull_request":{"url":"https://api.github.com/repos/mixmaxhq/install-files/pulls/6","id":106222383,"html_url":"https://github.com/mixmaxhq/install-files/pull/6","diff_url":"https://github.com/mixmaxhq/install-files/pull/6.diff","patch_url":"https://github.com/mixmaxhq/install-files/pull/6.patch","issue_url":"https://api.github.com/repos/mixmaxhq/install-files/issues/6","number":6,"state":"closed","locked":false,"title":"Remove broken guard","user":{"login":"wearhere","id":110000,"avatar_url":"https://avatars.githubusercontent.com/u/110000?v=3","gravatar_id":"","url":"https://api.github.com/users/wearhere","html_url":"https://github.com/wearhere","followers_url":"https://api.github.com/users/wearhere/followers","following_url":"https://api.github.com/users/wearhere/following{/other_user}","gists_url":"https://api.github.com/users/wearhere/gists{/gist_id}","starred_url":"https://api.github.com/users/wearhere/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wearhere/subscriptions","organizations_url":"https://api.github.com/users/wearhere/orgs","repos_url":"https://api.github.com/users/wearhere/repos","events_url":"https://api.github.com/users/wearhere/events{/privacy}","received_events_url":"https://api.github.com/users/wearhere/received_events","type":"User","site_admin":false},"body":"","created_at":"2017-02-15T00:38:07Z","updated_at":"2017-02-15T16:41:43Z","closed_at":"2017-02-15T00:39:18Z","merged_at":"2017-02-15T00:39:18Z","merge_commit_sha":"440fbc63067b62455c93615c0e09163d3aa521f7","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/mixmaxhq/install-files/pulls/6/commits","review_comments_url":"https://api.github.com/repos/mixmaxhq/install-files/pulls/6/comments","review_comment_url":"https://api.github.com/repos/mixmaxhq/install-files/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mixmaxhq/install-files/issues/6/comments","statuses_url":"https://api.github.com/repos/mixmaxhq/install-files/statuses/60a96146f85ccd55876a79487f983f9529aace93","head":{"label":"mixmaxhq:jeff/remove_broken_check","ref":"jeff/remove_broken_check","sha":"60a96146f85ccd55876a79487f983f9529aace93","user":{"login":"mixmaxhq","id":7530142,"avatar_url":"https://avatars.githubusercontent.com/u/7530142?v=3","gravatar_id":"","url":"https://api.github.com/users/mixmaxhq","html_url":"https://github.com/mixmaxhq","followers_url":"https://api.github.com/users/mixmaxhq/followers","following_url":"https://api.github.com/users/mixmaxhq/following{/other_user}","gists_url":"https://api.github.com/users/mixmaxhq/gists{/gist_id}","starred_url":"https://api.github.com/users/mixmaxhq/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mixmaxhq/subscriptions","organizations_url":"https://api.github.com/users/mixmaxhq/orgs","repos_url":"https://api.github.com/users/mixmaxhq/repos","events_url":"https://api.github.com/users/mixmaxhq/events{/privacy}","received_events_url":"https://api.github.com/users/mixmaxhq/received_events","type":"Organization","site_admin":false},"repo":{"id":64820679,"name":"install-files","full_name":"mixmaxhq/install-files","owner":{"login":"mixmaxhq","id":7530142,"avatar_url":"https://avatars.githubusercontent.com/u/7530142?v=3","gravatar_id":"","url":"https://api.github.com/users/mixmaxhq","html_url":"https://github.com/mixmaxhq","followers_url":"https://api.github.com/users/mixmaxhq/followers","following_url":"https://api.github.com/users/mixmaxhq/following{/other_user}","gists_url":"https://api.github.com/users/mixmaxhq/gists{/gist_id}","starred_url":"https://api.github.com/users/mixmaxhq/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mixmaxhq/subscriptions","organizations_url":"https://api.github.com/users/mixmaxhq/orgs","repos_url":"https://api.github.com/users/mixmaxhq/repos","events_url":"https://api.github.com/users/mixmaxhq/events{/privacy}","received_events_url":"https://api.github.com/users/mixmaxhq/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mixmaxhq/install-files","description":"Share files like you would code, using npm.","fork":false,"url":"https://api.github.com/repos/mixmaxhq/install-files","forks_url":"https://api.github.com/repos/mixmaxhq/install-files/forks","keys_url":"https://api.github.com/repos/mixmaxhq/install-files/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mixmaxhq/install-files/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mixmaxhq/install-files/teams","hooks_url":"https://api.github.com/repos/mixmaxhq/install-files/hooks","issue_events_url":"https://api.github.com/repos/mixmaxhq/install-files/issues/events{/number}","events_url":"https://api.github.com/repos/mixmaxhq/install-files/events","assignees_url":"https://api.github.com/repos/mixmaxhq/install-files/assignees{/user}","branches_url":"https://api.github.com/repos/mixmaxhq/install-files/branches{/branch}","tags_url":"https://api.github.com/repos/mixmaxhq/install-files/tags","blobs_url":"https://api.github.com/repos/mixmaxhq/install-files/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mixmaxhq/install-files/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mixmaxhq/install-files/git/refs{/sha}","trees_url":"https://api.github.com/repos/mixmaxhq/install-files/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mixmaxhq/install-files/statuses/{sha}","languages_url":"https://api.github.com/repos/mixmaxhq/install-files/languages","stargazers_url":"https://api.github.com/repos/mixmaxhq/install-files/stargazers","contributors_url":"https://api.github.com/repos/mixmaxhq/install-files/contributors","subscribers_url":"https://api.github.com/repos/mixmaxhq/install-files/subscribers","subscription_url":"https://api.github.com/repos/mixmaxhq/install-files/subscription","commits_url":"https://api.github.com/repos/mixmaxhq/install-files/commits{/sha}","git_commits_url":"https://api.github.com/repos/mixmaxhq/install-files/git/commits{/sha}","comments_url":"https://api.github.com/repos/mixmaxhq/install-files/comments{/number}","issue_comment_url":"https://api.github.com/repos/mixmaxhq/install-files/issues/comments{/number}","contents_url":"https://api.github.com/repos/mixmaxhq/install-files/contents/{+path}","compare_url":"https://api.github.com/repos/mixmaxhq/install-files/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mixmaxhq/install-files/merges","archive_url":"https://api.github.com/repos/mixmaxhq/install-files/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mixmaxhq/install-files/downloads","issues_url":"https://api.github.com/repos/mixmaxhq/install-files/issues{/number}","pulls_url":"https://api.github.com/repos/mixmaxhq/install-files/pulls{/number}","milestones_url":"https://api.github.com/repos/mixmaxhq/install-files/milestones{/number}","notifications_url":"https://api.github.com/repos/mixmaxhq/install-files/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mixmaxhq/install-files/labels{/name}","releases_url":"https://api.github.com/repos/mixmaxhq/install-files/releases{/id}","deployments_url":"https://api.github.com/repos/mixmaxhq/install-files/deployments","created_at":"2016-08-03T06:21:43Z","updated_at":"2017-02-08T20:48:18Z","pushed_at":"2017-02-15T00:40:15Z","git_url":"git://github.com/mixmaxhq/install-files.git","ssh_url":"git@github.com:mixmaxhq/install-files.git","clone_url":"https://github.com/mixmaxhq/install-files.git","svn_url":"https://github.com/mixmaxhq/install-files","homepage":null,"size":27,"stargazers_count":2,"watchers_count":2,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":2,"forks":1,"open_issues":2,"watchers":2,"default_branch":"master"}},"base":{"label":"mixmaxhq:master","ref":"master","sha":"d46f8d23bc378d209fc6c258851572b5ef79756b","user":{"login":"mixmaxhq","id":7530142,"avatar_url":"https://avatars.githubusercontent.com/u/7530142?v=3","gravatar_id":"","url":"https://api.github.com/users/mixmaxhq","html_url":"https://github.com/mixmaxhq","followers_url":"https://api.github.com/users/mixmaxhq/followers","following_url":"https://api.github.com/users/mixmaxhq/following{/other_user}","gists_url":"https://api.github.com/users/mixmaxhq/gists{/gist_id}","starred_url":"https://api.github.com/users/mixmaxhq/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mixmaxhq/subscriptions","organizations_url":"https://api.github.com/users/mixmaxhq/orgs","repos_url":"https://api.github.com/users/mixmaxhq/repos","events_url":"https://api.github.com/users/mixmaxhq/events{/privacy}","received_events_url":"https://api.github.com/users/mixmaxhq/received_events","type":"Organization","site_admin":false},"repo":{"id":64820679,"name":"install-files","full_name":"mixmaxhq/install-files","owner":{"login":"mixmaxhq","id":7530142,"avatar_url":"https://avatars.githubusercontent.com/u/7530142?v=3","gravatar_id":"","url":"https://api.github.com/users/mixmaxhq","html_url":"https://github.com/mixmaxhq","followers_url":"https://api.github.com/users/mixmaxhq/followers","following_url":"https://api.github.com/users/mixmaxhq/following{/other_user}","gists_url":"https://api.github.com/users/mixmaxhq/gists{/gist_id}","starred_url":"https://api.github.com/users/mixmaxhq/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mixmaxhq/subscriptions","organizations_url":"https://api.github.com/users/mixmaxhq/orgs","repos_url":"https://api.github.com/users/mixmaxhq/repos","events_url":"https://api.github.com/users/mixmaxhq/events{/privacy}","received_events_url":"https://api.github.com/users/mixmaxhq/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mixmaxhq/install-files","description":"Share files like you would code, using npm.","fork":false,"url":"https://api.github.com/repos/mixmaxhq/install-files","forks_url":"https://api.github.com/repos/mixmaxhq/install-files/forks","keys_url":"https://api.github.com/repos/mixmaxhq/install-files/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mixmaxhq/install-files/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mixmaxhq/install-files/teams","hooks_url":"https://api.github.com/repos/mixmaxhq/install-files/hooks","issue_events_url":"https://api.github.com/repos/mixmaxhq/install-files/issues/events{/number}","events_url":"https://api.github.com/repos/mixmaxhq/install-files/events","assignees_url":"https://api.github.com/repos/mixmaxhq/install-files/assignees{/user}","branches_url":"https://api.github.com/repos/mixmaxhq/install-files/branches{/branch}","tags_url":"https://api.github.com/repos/mixmaxhq/install-files/tags","blobs_url":"https://api.github.com/repos/mixmaxhq/install-files/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mixmaxhq/install-files/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mixmaxhq/install-files/git/refs{/sha}","trees_url":"https://api.github.com/repos/mixmaxhq/install-files/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mixmaxhq/install-files/statuses/{sha}","languages_url":"https://api.github.com/repos/mixmaxhq/install-files/languages","stargazers_url":"https://api.github.com/repos/mixmaxhq/install-files/stargazers","contributors_url":"https://api.github.com/repos/mixmaxhq/install-files/contributors","subscribers_url":"https://api.github.com/repos/mixmaxhq/install-files/subscribers","subscription_url":"https://api.github.com/repos/mixmaxhq/install-files/subscription","commits_url":"https://api.github.com/repos/mixmaxhq/install-files/commits{/sha}","git_commits_url":"https://api.github.com/repos/mixmaxhq/install-files/git/commits{/sha}","comments_url":"https://api.github.com/repos/mixmaxhq/install-files/comments{/number}","issue_comment_url":"https://api.github.com/repos/mixmaxhq/install-files/issues/comments{/number}","contents_url":"https://api.github.com/repos/mixmaxhq/install-files/contents/{+path}","compare_url":"https://api.github.com/repos/mixmaxhq/install-files/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mixmaxhq/install-files/merges","archive_url":"https://api.github.com/repos/mixmaxhq/install-files/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mixmaxhq/install-files/downloads","issues_url":"https://api.github.com/repos/mixmaxhq/install-files/issues{/number}","pulls_url":"https://api.github.com/repos/mixmaxhq/install-files/pulls{/number}","milestones_url":"https://api.github.com/repos/mixmaxhq/install-files/milestones{/number}","notifications_url":"https://api.github.com/repos/mixmaxhq/install-files/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mixmaxhq/install-files/labels{/name}","releases_url":"https://api.github.com/repos/mixmaxhq/install-files/releases{/id}","deployments_url":"https://api.github.com/repos/mixmaxhq/install-files/deployments","created_at":"2016-08-03T06:21:43Z","updated_at":"2017-02-08T20:48:18Z","pushed_at":"2017-02-15T00:40:15Z","git_url":"git://github.com/mixmaxhq/install-files.git","ssh_url":"git@github.com:mixmaxhq/install-files.git","clone_url":"https://github.com/mixmaxhq/install-files.git","svn_url":"https://github.com/mixmaxhq/install-files","homepage":null,"size":27,"stargazers_count":2,"watchers_count":2,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":2,"forks":1,"open_issues":2,"watchers":2,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/mixmaxhq/install-files/pulls/6"},"html":{"href":"https://github.com/mixmaxhq/install-files/pull/6"},"issue":{"href":"https://api.github.com/repos/mixmaxhq/install-files/issues/6"},"comments":{"href":"https://api.github.com/repos/mixmaxhq/install-files/issues/6/comments"},"review_comments":{"href":"https://api.github.com/repos/mixmaxhq/install-files/pulls/6/comments"},"review_comment":{"href":"https://api.github.com/repos/mixmaxhq/install-files/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mixmaxhq/install-files/pulls/6/commits"},"statuses":{"href":"https://api.github.com/repos/mixmaxhq/install-files/statuses/60a96146f85ccd55876a79487f983f9529aace93"}}}}
{"actor":{"display_login":"GoGoCarl"}}