{"action":"created","comment":{"url":"https://api.github.com/repos/gitskarios/Gitskarios/pulls/comments/67353785","id":67353785,"diff_hunk":"@@ -206,6 +219,59 @@ public void onContentMenuAction(Content content, MenuItem menuItem) {\n         Intent intent = ContentCommitsActivity.createLauncherIntent(getActivity(), repoInfo, content.path, content.name);\n         startActivity(intent);\n         break;\n+      case R.id.action_content_download:\n+        if (file.equals(content.type)) {\n+          FileInfo info = new FileInfo();\n+          info.repoInfo = repoInfo;\n+          info.path = content.path;\n+          info.name = content.name;\n+\n+          new GetFileContentClient(info).observable().subscribeOn(Schedulers.io()).observeOn(AndroidSchedulers.mainThread()).subscribe(new Subscriber<Content>() {\n+            @Override\n+            public void onCompleted() {\n+\n+            }\n+\n+            @Override\n+            public void onError(Throwable e) {\n+\n+            }\n+\n+            @Override\n+            public void onNext(Content content) {\n+              File downloadFolder = new File(Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_DOWNLOADS) + \"/gitskarios\");","path":"app/src/main/java/com/alorma/github/ui/fragment/detail/repo/SourceListFragment.java","position":77,"original_position":77,"commit_id":"3826c23496454718d897088923c1588ab87e8373","original_commit_id":"3826c23496454718d897088923c1588ab87e8373","user":{"login":"alorma","id":887462,"avatar_url":"https://avatars.githubusercontent.com/u/887462?v=3","gravatar_id":"","url":"https://api.github.com/users/alorma","html_url":"https://github.com/alorma","followers_url":"https://api.github.com/users/alorma/followers","following_url":"https://api.github.com/users/alorma/following{/other_user}","gists_url":"https://api.github.com/users/alorma/gists{/gist_id}","starred_url":"https://api.github.com/users/alorma/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alorma/subscriptions","organizations_url":"https://api.github.com/users/alorma/orgs","repos_url":"https://api.github.com/users/alorma/repos","events_url":"https://api.github.com/users/alorma/events{/privacy}","received_events_url":"https://api.github.com/users/alorma/received_events","type":"User","site_admin":false},"body":"Did you checked that the Write permission is granted?","created_at":"2016-06-16T14:24:50Z","updated_at":"2016-06-16T14:24:50Z","html_url":"https://github.com/gitskarios/Gitskarios/pull/465#discussion_r67353785","pull_request_url":"https://api.github.com/repos/gitskarios/Gitskarios/pulls/465","_links":{"self":{"href":"https://api.github.com/repos/gitskarios/Gitskarios/pulls/comments/67353785"},"html":{"href":"https://github.com/gitskarios/Gitskarios/pull/465#discussion_r67353785"},"pull_request":{"href":"https://api.github.com/repos/gitskarios/Gitskarios/pulls/465"}}},"pull_request":{"url":"https://api.github.com/repos/gitskarios/Gitskarios/pulls/465","id":73983955,"html_url":"https://github.com/gitskarios/Gitskarios/pull/465","diff_url":"https://github.com/gitskarios/Gitskarios/pull/465.diff","patch_url":"https://github.com/gitskarios/Gitskarios/pull/465.patch","issue_url":"https://api.github.com/repos/gitskarios/Gitskarios/issues/465","number":465,"state":"open","locked":false,"title":"Implement single file download #453","user":{"login":"shyim","id":6224096,"avatar_url":"https://avatars.githubusercontent.com/u/6224096?v=3","gravatar_id":"","url":"https://api.github.com/users/shyim","html_url":"https://github.com/shyim","followers_url":"https://api.github.com/users/shyim/followers","following_url":"https://api.github.com/users/shyim/following{/other_user}","gists_url":"https://api.github.com/users/shyim/gists{/gist_id}","starred_url":"https://api.github.com/users/shyim/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shyim/subscriptions","organizations_url":"https://api.github.com/users/shyim/orgs","repos_url":"https://api.github.com/users/shyim/repos","events_url":"https://api.github.com/users/shyim/events{/privacy}","received_events_url":"https://api.github.com/users/shyim/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-06-15T21:05:14Z","updated_at":"2016-06-16T14:24:50Z","closed_at":null,"merged_at":null,"merge_commit_sha":"75788e27a92e493494f16254e76ebfa452074b73","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/gitskarios/Gitskarios/pulls/465/commits","review_comments_url":"https://api.github.com/repos/gitskarios/Gitskarios/pulls/465/comments","review_comment_url":"https://api.github.com/repos/gitskarios/Gitskarios/pulls/comments{/number}","comments_url":"https://api.github.com/repos/gitskarios/Gitskarios/issues/465/comments","statuses_url":"https://api.github.com/repos/gitskarios/Gitskarios/statuses/3826c23496454718d897088923c1588ab87e8373","head":{"label":"gitskarios:single_file_download","ref":"single_file_download","sha":"3826c23496454718d897088923c1588ab87e8373","user":{"login":"gitskarios","id":11989662,"avatar_url":"https://avatars.githubusercontent.com/u/11989662?v=3","gravatar_id":"","url":"https://api.github.com/users/gitskarios","html_url":"https://github.com/gitskarios","followers_url":"https://api.github.com/users/gitskarios/followers","following_url":"https://api.github.com/users/gitskarios/following{/other_user}","gists_url":"https://api.github.com/users/gitskarios/gists{/gist_id}","starred_url":"https://api.github.com/users/gitskarios/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gitskarios/subscriptions","organizations_url":"https://api.github.com/users/gitskarios/orgs","repos_url":"https://api.github.com/users/gitskarios/repos","events_url":"https://api.github.com/users/gitskarios/events{/privacy}","received_events_url":"https://api.github.com/users/gitskarios/received_events","type":"Organization","site_admin":false},"repo":{"id":21775167,"name":"Gitskarios","full_name":"gitskarios/Gitskarios","owner":{"login":"gitskarios","id":11989662,"avatar_url":"https://avatars.githubusercontent.com/u/11989662?v=3","gravatar_id":"","url":"https://api.github.com/users/gitskarios","html_url":"https://github.com/gitskarios","followers_url":"https://api.github.com/users/gitskarios/followers","following_url":"https://api.github.com/users/gitskarios/following{/other_user}","gists_url":"https://api.github.com/users/gitskarios/gists{/gist_id}","starred_url":"https://api.github.com/users/gitskarios/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gitskarios/subscriptions","organizations_url":"https://api.github.com/users/gitskarios/orgs","repos_url":"https://api.github.com/users/gitskarios/repos","events_url":"https://api.github.com/users/gitskarios/events{/privacy}","received_events_url":"https://api.github.com/users/gitskarios/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/gitskarios/Gitskarios","description":"GitHub Android application","fork":false,"url":"https://api.github.com/repos/gitskarios/Gitskarios","forks_url":"https://api.github.com/repos/gitskarios/Gitskarios/forks","keys_url":"https://api.github.com/repos/gitskarios/Gitskarios/keys{/key_id}","collaborators_url":"https://api.github.com/repos/gitskarios/Gitskarios/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/gitskarios/Gitskarios/teams","hooks_url":"https://api.github.com/repos/gitskarios/Gitskarios/hooks","issue_events_url":"https://api.github.com/repos/gitskarios/Gitskarios/issues/events{/number}","events_url":"https://api.github.com/repos/gitskarios/Gitskarios/events","assignees_url":"https://api.github.com/repos/gitskarios/Gitskarios/assignees{/user}","branches_url":"https://api.github.com/repos/gitskarios/Gitskarios/branches{/branch}","tags_url":"https://api.github.com/repos/gitskarios/Gitskarios/tags","blobs_url":"https://api.github.com/repos/gitskarios/Gitskarios/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/gitskarios/Gitskarios/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/gitskarios/Gitskarios/git/refs{/sha}","trees_url":"https://api.github.com/repos/gitskarios/Gitskarios/git/trees{/sha}","statuses_url":"https://api.github.com/repos/gitskarios/Gitskarios/statuses/{sha}","languages_url":"https://api.github.com/repos/gitskarios/Gitskarios/languages","stargazers_url":"https://api.github.com/repos/gitskarios/Gitskarios/stargazers","contributors_url":"https://api.github.com/repos/gitskarios/Gitskarios/contributors","subscribers_url":"https://api.github.com/repos/gitskarios/Gitskarios/subscribers","subscription_url":"https://api.github.com/repos/gitskarios/Gitskarios/subscription","commits_url":"https://api.github.com/repos/gitskarios/Gitskarios/commits{/sha}","git_commits_url":"https://api.github.com/repos/gitskarios/Gitskarios/git/commits{/sha}","comments_url":"https://api.github.com/repos/gitskarios/Gitskarios/comments{/number}","issue_comment_url":"https://api.github.com/repos/gitskarios/Gitskarios/issues/comments{/number}","contents_url":"https://api.github.com/repos/gitskarios/Gitskarios/contents/{+path}","compare_url":"https://api.github.com/repos/gitskarios/Gitskarios/compare/{base}...{head}","merges_url":"https://api.github.com/repos/gitskarios/Gitskarios/merges","archive_url":"https://api.github.com/repos/gitskarios/Gitskarios/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/gitskarios/Gitskarios/downloads","issues_url":"https://api.github.com/repos/gitskarios/Gitskarios/issues{/number}","pulls_url":"https://api.github.com/repos/gitskarios/Gitskarios/pulls{/number}","milestones_url":"https://api.github.com/repos/gitskarios/Gitskarios/milestones{/number}","notifications_url":"https://api.github.com/repos/gitskarios/Gitskarios/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/gitskarios/Gitskarios/labels{/name}","releases_url":"https://api.github.com/repos/gitskarios/Gitskarios/releases{/id}","deployments_url":"https://api.github.com/repos/gitskarios/Gitskarios/deployments","created_at":"2014-07-12T19:46:18Z","updated_at":"2016-06-16T02:36:38Z","pushed_at":"2016-06-16T14:21:17Z","git_url":"git://github.com/gitskarios/Gitskarios.git","ssh_url":"git@github.com:gitskarios/Gitskarios.git","clone_url":"https://github.com/gitskarios/Gitskarios.git","svn_url":"https://github.com/gitskarios/Gitskarios","homepage":"http://gitskarios.com/","size":38019,"stargazers_count":441,"watchers_count":441,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":72,"mirror_url":null,"open_issues_count":20,"forks":72,"open_issues":20,"watchers":441,"default_branch":"develop"}},"base":{"label":"gitskarios:develop","ref":"develop","sha":"6bf17c314a6549ee1835de1be982b51f9e620116","user":{"login":"gitskarios","id":11989662,"avatar_url":"https://avatars.githubusercontent.com/u/11989662?v=3","gravatar_id":"","url":"https://api.github.com/users/gitskarios","html_url":"https://github.com/gitskarios","followers_url":"https://api.github.com/users/gitskarios/followers","following_url":"https://api.github.com/users/gitskarios/following{/other_user}","gists_url":"https://api.github.com/users/gitskarios/gists{/gist_id}","starred_url":"https://api.github.com/users/gitskarios/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gitskarios/subscriptions","organizations_url":"https://api.github.com/users/gitskarios/orgs","repos_url":"https://api.github.com/users/gitskarios/repos","events_url":"https://api.github.com/users/gitskarios/events{/privacy}","received_events_url":"https://api.github.com/users/gitskarios/received_events","type":"Organization","site_admin":false},"repo":{"id":21775167,"name":"Gitskarios","full_name":"gitskarios/Gitskarios","owner":{"login":"gitskarios","id":11989662,"avatar_url":"https://avatars.githubusercontent.com/u/11989662?v=3","gravatar_id":"","url":"https://api.github.com/users/gitskarios","html_url":"https://github.com/gitskarios","followers_url":"https://api.github.com/users/gitskarios/followers","following_url":"https://api.github.com/users/gitskarios/following{/other_user}","gists_url":"https://api.github.com/users/gitskarios/gists{/gist_id}","starred_url":"https://api.github.com/users/gitskarios/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gitskarios/subscriptions","organizations_url":"https://api.github.com/users/gitskarios/orgs","repos_url":"https://api.github.com/users/gitskarios/repos","events_url":"https://api.github.com/users/gitskarios/events{/privacy}","received_events_url":"https://api.github.com/users/gitskarios/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/gitskarios/Gitskarios","description":"GitHub Android application","fork":false,"url":"https://api.github.com/repos/gitskarios/Gitskarios","forks_url":"https://api.github.com/repos/gitskarios/Gitskarios/forks","keys_url":"https://api.github.com/repos/gitskarios/Gitskarios/keys{/key_id}","collaborators_url":"https://api.github.com/repos/gitskarios/Gitskarios/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/gitskarios/Gitskarios/teams","hooks_url":"https://api.github.com/repos/gitskarios/Gitskarios/hooks","issue_events_url":"https://api.github.com/repos/gitskarios/Gitskarios/issues/events{/number}","events_url":"https://api.github.com/repos/gitskarios/Gitskarios/events","assignees_url":"https://api.github.com/repos/gitskarios/Gitskarios/assignees{/user}","branches_url":"https://api.github.com/repos/gitskarios/Gitskarios/branches{/branch}","tags_url":"https://api.github.com/repos/gitskarios/Gitskarios/tags","blobs_url":"https://api.github.com/repos/gitskarios/Gitskarios/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/gitskarios/Gitskarios/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/gitskarios/Gitskarios/git/refs{/sha}","trees_url":"https://api.github.com/repos/gitskarios/Gitskarios/git/trees{/sha}","statuses_url":"https://api.github.com/repos/gitskarios/Gitskarios/statuses/{sha}","languages_url":"https://api.github.com/repos/gitskarios/Gitskarios/languages","stargazers_url":"https://api.github.com/repos/gitskarios/Gitskarios/stargazers","contributors_url":"https://api.github.com/repos/gitskarios/Gitskarios/contributors","subscribers_url":"https://api.github.com/repos/gitskarios/Gitskarios/subscribers","subscription_url":"https://api.github.com/repos/gitskarios/Gitskarios/subscription","commits_url":"https://api.github.com/repos/gitskarios/Gitskarios/commits{/sha}","git_commits_url":"https://api.github.com/repos/gitskarios/Gitskarios/git/commits{/sha}","comments_url":"https://api.github.com/repos/gitskarios/Gitskarios/comments{/number}","issue_comment_url":"https://api.github.com/repos/gitskarios/Gitskarios/issues/comments{/number}","contents_url":"https://api.github.com/repos/gitskarios/Gitskarios/contents/{+path}","compare_url":"https://api.github.com/repos/gitskarios/Gitskarios/compare/{base}...{head}","merges_url":"https://api.github.com/repos/gitskarios/Gitskarios/merges","archive_url":"https://api.github.com/repos/gitskarios/Gitskarios/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/gitskarios/Gitskarios/downloads","issues_url":"https://api.github.com/repos/gitskarios/Gitskarios/issues{/number}","pulls_url":"https://api.github.com/repos/gitskarios/Gitskarios/pulls{/number}","milestones_url":"https://api.github.com/repos/gitskarios/Gitskarios/milestones{/number}","notifications_url":"https://api.github.com/repos/gitskarios/Gitskarios/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/gitskarios/Gitskarios/labels{/name}","releases_url":"https://api.github.com/repos/gitskarios/Gitskarios/releases{/id}","deployments_url":"https://api.github.com/repos/gitskarios/Gitskarios/deployments","created_at":"2014-07-12T19:46:18Z","updated_at":"2016-06-16T02:36:38Z","pushed_at":"2016-06-16T14:21:17Z","git_url":"git://github.com/gitskarios/Gitskarios.git","ssh_url":"git@github.com:gitskarios/Gitskarios.git","clone_url":"https://github.com/gitskarios/Gitskarios.git","svn_url":"https://github.com/gitskarios/Gitskarios","homepage":"http://gitskarios.com/","size":38019,"stargazers_count":441,"watchers_count":441,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":72,"mirror_url":null,"open_issues_count":20,"forks":72,"open_issues":20,"watchers":441,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/gitskarios/Gitskarios/pulls/465"},"html":{"href":"https://github.com/gitskarios/Gitskarios/pull/465"},"issue":{"href":"https://api.github.com/repos/gitskarios/Gitskarios/issues/465"},"comments":{"href":"https://api.github.com/repos/gitskarios/Gitskarios/issues/465/comments"},"review_comments":{"href":"https://api.github.com/repos/gitskarios/Gitskarios/pulls/465/comments"},"review_comment":{"href":"https://api.github.com/repos/gitskarios/Gitskarios/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/gitskarios/Gitskarios/pulls/465/commits"},"statuses":{"href":"https://api.github.com/repos/gitskarios/Gitskarios/statuses/3826c23496454718d897088923c1588ab87e8373"}}}}
{"actor":{"display_login":"alorma"}}