{"action":"created","comment":{"url":"https://api.github.com/repos/coala-analyzer/coala/pulls/comments/68499846","id":68499846,"diff_hunk":"@@ -119,3 +120,19 @@ def multiple(cls, *args):\n                 else:\n                     raise TypeError('Too many elements provided.')\n             return set(reqs)\n+\n+    @classmethod\n+    def upload(self):\n+        \"\"\"\n+        An upload method which uploads a conda package containing the command\n+        to install the corresponding package.\n+        \"\"\"\n+        name = self.package\n+        if not os.path.exists(name):\n+            os.mkdir(name)\n+        file = open(name + '/' + name + '.py', 'a')\n+        file.write(self.manager + ' ' + self.package)","path":"coalib/bears/requirements/PackageRequirement.py","position":21,"original_position":21,"commit_id":"a277ca897b7ff26bec62ca795fd7f187b7e9bd0e","original_commit_id":"a277ca897b7ff26bec62ca795fd7f187b7e9bd0e","user":{"login":"tushar-rishav","id":7397433,"avatar_url":"https://avatars.githubusercontent.com/u/7397433?v=3","gravatar_id":"","url":"https://api.github.com/users/tushar-rishav","html_url":"https://github.com/tushar-rishav","followers_url":"https://api.github.com/users/tushar-rishav/followers","following_url":"https://api.github.com/users/tushar-rishav/following{/other_user}","gists_url":"https://api.github.com/users/tushar-rishav/gists{/gist_id}","starred_url":"https://api.github.com/users/tushar-rishav/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tushar-rishav/subscriptions","organizations_url":"https://api.github.com/users/tushar-rishav/orgs","repos_url":"https://api.github.com/users/tushar-rishav/repos","events_url":"https://api.github.com/users/tushar-rishav/events{/privacy}","received_events_url":"https://api.github.com/users/tushar-rishav/received_events","type":"User","site_admin":false},"body":"Also I think the current file I/O approach can be made better. This is more pythonic and you won't have to close the file descriptor explicitly :\r\n```python\r\nwith open(os.path.join('name','name.py'), 'a') as package_file:\r\n    package_file.write(\"{manager} {package}\".format(manager=self.manager, \r\n                                                    package=self.package))\r\n```","created_at":"2016-06-26T09:03:23Z","updated_at":"2016-06-26T09:03:23Z","html_url":"https://github.com/coala-analyzer/coala/pull/2391#discussion_r68499846","pull_request_url":"https://api.github.com/repos/coala-analyzer/coala/pulls/2391","_links":{"self":{"href":"https://api.github.com/repos/coala-analyzer/coala/pulls/comments/68499846"},"html":{"href":"https://github.com/coala-analyzer/coala/pull/2391#discussion_r68499846"},"pull_request":{"href":"https://api.github.com/repos/coala-analyzer/coala/pulls/2391"}}},"pull_request":{"url":"https://api.github.com/repos/coala-analyzer/coala/pulls/2391","id":75213612,"html_url":"https://github.com/coala-analyzer/coala/pull/2391","diff_url":"https://github.com/coala-analyzer/coala/pull/2391.diff","patch_url":"https://github.com/coala-analyzer/coala/pull/2391.patch","issue_url":"https://api.github.com/repos/coala-analyzer/coala/issues/2391","number":2391,"state":"open","locked":false,"title":"Uploadmethod","user":{"login":"Adrianzatreanu","id":15572459,"avatar_url":"https://avatars.githubusercontent.com/u/15572459?v=3","gravatar_id":"","url":"https://api.github.com/users/Adrianzatreanu","html_url":"https://github.com/Adrianzatreanu","followers_url":"https://api.github.com/users/Adrianzatreanu/followers","following_url":"https://api.github.com/users/Adrianzatreanu/following{/other_user}","gists_url":"https://api.github.com/users/Adrianzatreanu/gists{/gist_id}","starred_url":"https://api.github.com/users/Adrianzatreanu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Adrianzatreanu/subscriptions","organizations_url":"https://api.github.com/users/Adrianzatreanu/orgs","repos_url":"https://api.github.com/users/Adrianzatreanu/repos","events_url":"https://api.github.com/users/Adrianzatreanu/events{/privacy}","received_events_url":"https://api.github.com/users/Adrianzatreanu/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-06-25T20:23:42Z","updated_at":"2016-06-26T09:03:23Z","closed_at":null,"merged_at":null,"merge_commit_sha":"f7a4569b41c4d140ae98d7ae8dcd56eab3f1f086","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/coala-analyzer/coala/pulls/2391/commits","review_comments_url":"https://api.github.com/repos/coala-analyzer/coala/pulls/2391/comments","review_comment_url":"https://api.github.com/repos/coala-analyzer/coala/pulls/comments{/number}","comments_url":"https://api.github.com/repos/coala-analyzer/coala/issues/2391/comments","statuses_url":"https://api.github.com/repos/coala-analyzer/coala/statuses/a277ca897b7ff26bec62ca795fd7f187b7e9bd0e","head":{"label":"Adrianzatreanu:uploadmethod","ref":"uploadmethod","sha":"a277ca897b7ff26bec62ca795fd7f187b7e9bd0e","user":{"login":"Adrianzatreanu","id":15572459,"avatar_url":"https://avatars.githubusercontent.com/u/15572459?v=3","gravatar_id":"","url":"https://api.github.com/users/Adrianzatreanu","html_url":"https://github.com/Adrianzatreanu","followers_url":"https://api.github.com/users/Adrianzatreanu/followers","following_url":"https://api.github.com/users/Adrianzatreanu/following{/other_user}","gists_url":"https://api.github.com/users/Adrianzatreanu/gists{/gist_id}","starred_url":"https://api.github.com/users/Adrianzatreanu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Adrianzatreanu/subscriptions","organizations_url":"https://api.github.com/users/Adrianzatreanu/orgs","repos_url":"https://api.github.com/users/Adrianzatreanu/repos","events_url":"https://api.github.com/users/Adrianzatreanu/events{/privacy}","received_events_url":"https://api.github.com/users/Adrianzatreanu/received_events","type":"User","site_admin":false},"repo":{"id":52313604,"name":"coala","full_name":"Adrianzatreanu/coala","owner":{"login":"Adrianzatreanu","id":15572459,"avatar_url":"https://avatars.githubusercontent.com/u/15572459?v=3","gravatar_id":"","url":"https://api.github.com/users/Adrianzatreanu","html_url":"https://github.com/Adrianzatreanu","followers_url":"https://api.github.com/users/Adrianzatreanu/followers","following_url":"https://api.github.com/users/Adrianzatreanu/following{/other_user}","gists_url":"https://api.github.com/users/Adrianzatreanu/gists{/gist_id}","starred_url":"https://api.github.com/users/Adrianzatreanu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Adrianzatreanu/subscriptions","organizations_url":"https://api.github.com/users/Adrianzatreanu/orgs","repos_url":"https://api.github.com/users/Adrianzatreanu/repos","events_url":"https://api.github.com/users/Adrianzatreanu/events{/privacy}","received_events_url":"https://api.github.com/users/Adrianzatreanu/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Adrianzatreanu/coala","description":"Easy to use COde AnaLysis Application - yes! For all languages!","fork":true,"url":"https://api.github.com/repos/Adrianzatreanu/coala","forks_url":"https://api.github.com/repos/Adrianzatreanu/coala/forks","keys_url":"https://api.github.com/repos/Adrianzatreanu/coala/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Adrianzatreanu/coala/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Adrianzatreanu/coala/teams","hooks_url":"https://api.github.com/repos/Adrianzatreanu/coala/hooks","issue_events_url":"https://api.github.com/repos/Adrianzatreanu/coala/issues/events{/number}","events_url":"https://api.github.com/repos/Adrianzatreanu/coala/events","assignees_url":"https://api.github.com/repos/Adrianzatreanu/coala/assignees{/user}","branches_url":"https://api.github.com/repos/Adrianzatreanu/coala/branches{/branch}","tags_url":"https://api.github.com/repos/Adrianzatreanu/coala/tags","blobs_url":"https://api.github.com/repos/Adrianzatreanu/coala/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Adrianzatreanu/coala/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Adrianzatreanu/coala/git/refs{/sha}","trees_url":"https://api.github.com/repos/Adrianzatreanu/coala/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Adrianzatreanu/coala/statuses/{sha}","languages_url":"https://api.github.com/repos/Adrianzatreanu/coala/languages","stargazers_url":"https://api.github.com/repos/Adrianzatreanu/coala/stargazers","contributors_url":"https://api.github.com/repos/Adrianzatreanu/coala/contributors","subscribers_url":"https://api.github.com/repos/Adrianzatreanu/coala/subscribers","subscription_url":"https://api.github.com/repos/Adrianzatreanu/coala/subscription","commits_url":"https://api.github.com/repos/Adrianzatreanu/coala/commits{/sha}","git_commits_url":"https://api.github.com/repos/Adrianzatreanu/coala/git/commits{/sha}","comments_url":"https://api.github.com/repos/Adrianzatreanu/coala/comments{/number}","issue_comment_url":"https://api.github.com/repos/Adrianzatreanu/coala/issues/comments{/number}","contents_url":"https://api.github.com/repos/Adrianzatreanu/coala/contents/{+path}","compare_url":"https://api.github.com/repos/Adrianzatreanu/coala/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Adrianzatreanu/coala/merges","archive_url":"https://api.github.com/repos/Adrianzatreanu/coala/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Adrianzatreanu/coala/downloads","issues_url":"https://api.github.com/repos/Adrianzatreanu/coala/issues{/number}","pulls_url":"https://api.github.com/repos/Adrianzatreanu/coala/pulls{/number}","milestones_url":"https://api.github.com/repos/Adrianzatreanu/coala/milestones{/number}","notifications_url":"https://api.github.com/repos/Adrianzatreanu/coala/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Adrianzatreanu/coala/labels{/name}","releases_url":"https://api.github.com/repos/Adrianzatreanu/coala/releases{/id}","deployments_url":"https://api.github.com/repos/Adrianzatreanu/coala/deployments","created_at":"2016-02-22T23:21:25Z","updated_at":"2016-02-22T23:21:27Z","pushed_at":"2016-06-25T20:23:40Z","git_url":"git://github.com/Adrianzatreanu/coala.git","ssh_url":"git@github.com:Adrianzatreanu/coala.git","clone_url":"https://github.com/Adrianzatreanu/coala.git","svn_url":"https://github.com/Adrianzatreanu/coala","homepage":"http://coala-analyzer.org/","size":9910,"stargazers_count":0,"watchers_count":0,"language":"Python","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":"coala-analyzer:master","ref":"master","sha":"c959bd476030a4b2fb9275cc217f1c878749033e","user":{"login":"coala-analyzer","id":10620750,"avatar_url":"https://avatars.githubusercontent.com/u/10620750?v=3","gravatar_id":"","url":"https://api.github.com/users/coala-analyzer","html_url":"https://github.com/coala-analyzer","followers_url":"https://api.github.com/users/coala-analyzer/followers","following_url":"https://api.github.com/users/coala-analyzer/following{/other_user}","gists_url":"https://api.github.com/users/coala-analyzer/gists{/gist_id}","starred_url":"https://api.github.com/users/coala-analyzer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/coala-analyzer/subscriptions","organizations_url":"https://api.github.com/users/coala-analyzer/orgs","repos_url":"https://api.github.com/users/coala-analyzer/repos","events_url":"https://api.github.com/users/coala-analyzer/events{/privacy}","received_events_url":"https://api.github.com/users/coala-analyzer/received_events","type":"Organization","site_admin":false},"repo":{"id":19816973,"name":"coala","full_name":"coala-analyzer/coala","owner":{"login":"coala-analyzer","id":10620750,"avatar_url":"https://avatars.githubusercontent.com/u/10620750?v=3","gravatar_id":"","url":"https://api.github.com/users/coala-analyzer","html_url":"https://github.com/coala-analyzer","followers_url":"https://api.github.com/users/coala-analyzer/followers","following_url":"https://api.github.com/users/coala-analyzer/following{/other_user}","gists_url":"https://api.github.com/users/coala-analyzer/gists{/gist_id}","starred_url":"https://api.github.com/users/coala-analyzer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/coala-analyzer/subscriptions","organizations_url":"https://api.github.com/users/coala-analyzer/orgs","repos_url":"https://api.github.com/users/coala-analyzer/repos","events_url":"https://api.github.com/users/coala-analyzer/events{/privacy}","received_events_url":"https://api.github.com/users/coala-analyzer/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/coala-analyzer/coala","description":"Easy to use code analysis framework/application - yes! For all languages!","fork":false,"url":"https://api.github.com/repos/coala-analyzer/coala","forks_url":"https://api.github.com/repos/coala-analyzer/coala/forks","keys_url":"https://api.github.com/repos/coala-analyzer/coala/keys{/key_id}","collaborators_url":"https://api.github.com/repos/coala-analyzer/coala/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/coala-analyzer/coala/teams","hooks_url":"https://api.github.com/repos/coala-analyzer/coala/hooks","issue_events_url":"https://api.github.com/repos/coala-analyzer/coala/issues/events{/number}","events_url":"https://api.github.com/repos/coala-analyzer/coala/events","assignees_url":"https://api.github.com/repos/coala-analyzer/coala/assignees{/user}","branches_url":"https://api.github.com/repos/coala-analyzer/coala/branches{/branch}","tags_url":"https://api.github.com/repos/coala-analyzer/coala/tags","blobs_url":"https://api.github.com/repos/coala-analyzer/coala/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/coala-analyzer/coala/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/coala-analyzer/coala/git/refs{/sha}","trees_url":"https://api.github.com/repos/coala-analyzer/coala/git/trees{/sha}","statuses_url":"https://api.github.com/repos/coala-analyzer/coala/statuses/{sha}","languages_url":"https://api.github.com/repos/coala-analyzer/coala/languages","stargazers_url":"https://api.github.com/repos/coala-analyzer/coala/stargazers","contributors_url":"https://api.github.com/repos/coala-analyzer/coala/contributors","subscribers_url":"https://api.github.com/repos/coala-analyzer/coala/subscribers","subscription_url":"https://api.github.com/repos/coala-analyzer/coala/subscription","commits_url":"https://api.github.com/repos/coala-analyzer/coala/commits{/sha}","git_commits_url":"https://api.github.com/repos/coala-analyzer/coala/git/commits{/sha}","comments_url":"https://api.github.com/repos/coala-analyzer/coala/comments{/number}","issue_comment_url":"https://api.github.com/repos/coala-analyzer/coala/issues/comments{/number}","contents_url":"https://api.github.com/repos/coala-analyzer/coala/contents/{+path}","compare_url":"https://api.github.com/repos/coala-analyzer/coala/compare/{base}...{head}","merges_url":"https://api.github.com/repos/coala-analyzer/coala/merges","archive_url":"https://api.github.com/repos/coala-analyzer/coala/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/coala-analyzer/coala/downloads","issues_url":"https://api.github.com/repos/coala-analyzer/coala/issues{/number}","pulls_url":"https://api.github.com/repos/coala-analyzer/coala/pulls{/number}","milestones_url":"https://api.github.com/repos/coala-analyzer/coala/milestones{/number}","notifications_url":"https://api.github.com/repos/coala-analyzer/coala/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/coala-analyzer/coala/labels{/name}","releases_url":"https://api.github.com/repos/coala-analyzer/coala/releases{/id}","deployments_url":"https://api.github.com/repos/coala-analyzer/coala/deployments","created_at":"2014-05-15T11:35:34Z","updated_at":"2016-06-24T17:50:52Z","pushed_at":"2016-06-26T00:02:21Z","git_url":"git://github.com/coala-analyzer/coala.git","ssh_url":"git@github.com:coala-analyzer/coala.git","clone_url":"https://github.com/coala-analyzer/coala.git","svn_url":"https://github.com/coala-analyzer/coala","homepage":"http://coala-analyzer.org/","size":11972,"stargazers_count":241,"watchers_count":241,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":149,"mirror_url":null,"open_issues_count":204,"forks":149,"open_issues":204,"watchers":241,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/coala-analyzer/coala/pulls/2391"},"html":{"href":"https://github.com/coala-analyzer/coala/pull/2391"},"issue":{"href":"https://api.github.com/repos/coala-analyzer/coala/issues/2391"},"comments":{"href":"https://api.github.com/repos/coala-analyzer/coala/issues/2391/comments"},"review_comments":{"href":"https://api.github.com/repos/coala-analyzer/coala/pulls/2391/comments"},"review_comment":{"href":"https://api.github.com/repos/coala-analyzer/coala/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/coala-analyzer/coala/pulls/2391/commits"},"statuses":{"href":"https://api.github.com/repos/coala-analyzer/coala/statuses/a277ca897b7ff26bec62ca795fd7f187b7e9bd0e"}}}}
{"actor":{"display_login":"tushar-rishav"}}