{"action":"created","comment":{"url":"https://api.github.com/repos/ENOFLAG/ENOKEY/pulls/comments/234440267","pull_request_review_id":176085515,"id":234440267,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIzNDQ0MDI2Nw==","diff_hunk":"@@ -1,22 +1,66 @@\n+use std::fs;\n+use std::fs::File;\n+use std::io::Write;\n+use std::io::Read;\n+\n use error::EnokeysError;\n \n-pub fn fetch_github(user: &str) -> Result<Vec<String>, EnokeysError> {\n-    let mut res = reqwest::get(&format!(\"https://www.github.com/{}.keys\",user))?;\n-    assert_eq!(res.status(),200);\n-    Ok(res.text().unwrap().split(\"\\n\").filter(|&i|!i.is_empty()).map(|s|format!(\"{} {}@github\", s, user)).collect::<Vec<String>>())\n+const GITHUB: &'static str = \"github\";\n+const GITLAB: &'static str = \"gitlab\";\n+const TUBLAB: &'static str = \"tublab\";\n+const ENOLAB: &'static str = \"enolab\";\n+\n+pub fn fetch(user: &str, provider: &str) -> Result<Vec<String>, EnokeysError> {\n+    let url = get_url(&user, &provider)?;","path":"src/scraper.rs","position":18,"original_position":18,"commit_id":"8fbd4568a7e73571fb9076859dc028245622f981","original_commit_id":"8fbd4568a7e73571fb9076859dc028245622f981","user":{"login":"fsck","id":17763262,"node_id":"MDQ6VXNlcjE3NzYzMjYy","avatar_url":"https://avatars0.githubusercontent.com/u/17763262?v=4","gravatar_id":"","url":"https://api.github.com/users/fsck","html_url":"https://github.com/fsck","followers_url":"https://api.github.com/users/fsck/followers","following_url":"https://api.github.com/users/fsck/following{/other_user}","gists_url":"https://api.github.com/users/fsck/gists{/gist_id}","starred_url":"https://api.github.com/users/fsck/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fsck/subscriptions","organizations_url":"https://api.github.com/users/fsck/orgs","repos_url":"https://api.github.com/users/fsck/repos","events_url":"https://api.github.com/users/fsck/events{/privacy}","received_events_url":"https://api.github.com/users/fsck/received_events","type":"User","site_admin":false},"body":"I am open for other suggestions, but I thought it might be easiest here as all the keys go through this path and we can handle it as a simple case. ","created_at":"2018-11-18T11:35:46Z","updated_at":"2018-11-18T11:35:46Z","html_url":"https://github.com/ENOFLAG/ENOKEY/pull/2#discussion_r234440267","pull_request_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/pulls/2","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/ENOFLAG/ENOKEY/pulls/comments/234440267"},"html":{"href":"https://github.com/ENOFLAG/ENOKEY/pull/2#discussion_r234440267"},"pull_request":{"href":"https://api.github.com/repos/ENOFLAG/ENOKEY/pulls/2"}},"in_reply_to_id":234438616},"pull_request":{"url":"https://api.github.com/repos/ENOFLAG/ENOKEY/pulls/2","id":231733163,"node_id":"MDExOlB1bGxSZXF1ZXN0MjMxNzMzMTYz","html_url":"https://github.com/ENOFLAG/ENOKEY/pull/2","diff_url":"https://github.com/ENOFLAG/ENOKEY/pull/2.diff","patch_url":"https://github.com/ENOFLAG/ENOKEY/pull/2.patch","issue_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/issues/2","number":2,"state":"open","locked":false,"title":"Cleanup","user":{"login":"Trolldemorted","id":10261186,"node_id":"MDQ6VXNlcjEwMjYxMTg2","avatar_url":"https://avatars3.githubusercontent.com/u/10261186?v=4","gravatar_id":"","url":"https://api.github.com/users/Trolldemorted","html_url":"https://github.com/Trolldemorted","followers_url":"https://api.github.com/users/Trolldemorted/followers","following_url":"https://api.github.com/users/Trolldemorted/following{/other_user}","gists_url":"https://api.github.com/users/Trolldemorted/gists{/gist_id}","starred_url":"https://api.github.com/users/Trolldemorted/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Trolldemorted/subscriptions","organizations_url":"https://api.github.com/users/Trolldemorted/orgs","repos_url":"https://api.github.com/users/Trolldemorted/repos","events_url":"https://api.github.com/users/Trolldemorted/events{/privacy}","received_events_url":"https://api.github.com/users/Trolldemorted/received_events","type":"User","site_admin":false},"body":"","created_at":"2018-11-17T15:16:38Z","updated_at":"2018-11-18T11:35:46Z","closed_at":null,"merged_at":null,"merge_commit_sha":"7950fcc5105e23526f0331978ed5874bfc65dc0f","assignee":{"login":"fsck","id":17763262,"node_id":"MDQ6VXNlcjE3NzYzMjYy","avatar_url":"https://avatars0.githubusercontent.com/u/17763262?v=4","gravatar_id":"","url":"https://api.github.com/users/fsck","html_url":"https://github.com/fsck","followers_url":"https://api.github.com/users/fsck/followers","following_url":"https://api.github.com/users/fsck/following{/other_user}","gists_url":"https://api.github.com/users/fsck/gists{/gist_id}","starred_url":"https://api.github.com/users/fsck/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fsck/subscriptions","organizations_url":"https://api.github.com/users/fsck/orgs","repos_url":"https://api.github.com/users/fsck/repos","events_url":"https://api.github.com/users/fsck/events{/privacy}","received_events_url":"https://api.github.com/users/fsck/received_events","type":"User","site_admin":false},"assignees":[{"login":"fsck","id":17763262,"node_id":"MDQ6VXNlcjE3NzYzMjYy","avatar_url":"https://avatars0.githubusercontent.com/u/17763262?v=4","gravatar_id":"","url":"https://api.github.com/users/fsck","html_url":"https://github.com/fsck","followers_url":"https://api.github.com/users/fsck/followers","following_url":"https://api.github.com/users/fsck/following{/other_user}","gists_url":"https://api.github.com/users/fsck/gists{/gist_id}","starred_url":"https://api.github.com/users/fsck/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fsck/subscriptions","organizations_url":"https://api.github.com/users/fsck/orgs","repos_url":"https://api.github.com/users/fsck/repos","events_url":"https://api.github.com/users/fsck/events{/privacy}","received_events_url":"https://api.github.com/users/fsck/received_events","type":"User","site_admin":false}],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/pulls/2/commits","review_comments_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/pulls/2/comments","review_comment_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/issues/2/comments","statuses_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/statuses/8fbd4568a7e73571fb9076859dc028245622f981","head":{"label":"ENOFLAG:cleanup","ref":"cleanup","sha":"8fbd4568a7e73571fb9076859dc028245622f981","user":{"login":"ENOFLAG","id":29580191,"node_id":"MDEyOk9yZ2FuaXphdGlvbjI5NTgwMTkx","avatar_url":"https://avatars2.githubusercontent.com/u/29580191?v=4","gravatar_id":"","url":"https://api.github.com/users/ENOFLAG","html_url":"https://github.com/ENOFLAG","followers_url":"https://api.github.com/users/ENOFLAG/followers","following_url":"https://api.github.com/users/ENOFLAG/following{/other_user}","gists_url":"https://api.github.com/users/ENOFLAG/gists{/gist_id}","starred_url":"https://api.github.com/users/ENOFLAG/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ENOFLAG/subscriptions","organizations_url":"https://api.github.com/users/ENOFLAG/orgs","repos_url":"https://api.github.com/users/ENOFLAG/repos","events_url":"https://api.github.com/users/ENOFLAG/events{/privacy}","received_events_url":"https://api.github.com/users/ENOFLAG/received_events","type":"Organization","site_admin":false},"repo":{"id":157967251,"node_id":"MDEwOlJlcG9zaXRvcnkxNTc5NjcyNTE=","name":"ENOKEY","full_name":"ENOFLAG/ENOKEY","private":false,"owner":{"login":"ENOFLAG","id":29580191,"node_id":"MDEyOk9yZ2FuaXphdGlvbjI5NTgwMTkx","avatar_url":"https://avatars2.githubusercontent.com/u/29580191?v=4","gravatar_id":"","url":"https://api.github.com/users/ENOFLAG","html_url":"https://github.com/ENOFLAG","followers_url":"https://api.github.com/users/ENOFLAG/followers","following_url":"https://api.github.com/users/ENOFLAG/following{/other_user}","gists_url":"https://api.github.com/users/ENOFLAG/gists{/gist_id}","starred_url":"https://api.github.com/users/ENOFLAG/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ENOFLAG/subscriptions","organizations_url":"https://api.github.com/users/ENOFLAG/orgs","repos_url":"https://api.github.com/users/ENOFLAG/repos","events_url":"https://api.github.com/users/ENOFLAG/events{/privacy}","received_events_url":"https://api.github.com/users/ENOFLAG/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/ENOFLAG/ENOKEY","description":"This is the ENOKEY project for handling ssh keys","fork":false,"url":"https://api.github.com/repos/ENOFLAG/ENOKEY","forks_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/forks","keys_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/teams","hooks_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/hooks","issue_events_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/issues/events{/number}","events_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/events","assignees_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/assignees{/user}","branches_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/branches{/branch}","tags_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/tags","blobs_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/git/refs{/sha}","trees_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/statuses/{sha}","languages_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/languages","stargazers_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/stargazers","contributors_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/contributors","subscribers_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/subscribers","subscription_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/subscription","commits_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/commits{/sha}","git_commits_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/git/commits{/sha}","comments_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/comments{/number}","issue_comment_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/issues/comments{/number}","contents_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/contents/{+path}","compare_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/merges","archive_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/downloads","issues_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/issues{/number}","pulls_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/pulls{/number}","milestones_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/milestones{/number}","notifications_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/labels{/name}","releases_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/releases{/id}","deployments_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/deployments","created_at":"2018-11-17T08:53:45Z","updated_at":"2018-11-18T10:42:45Z","pushed_at":"2018-11-18T10:42:52Z","git_url":"git://github.com/ENOFLAG/ENOKEY.git","ssh_url":"git@github.com:ENOFLAG/ENOKEY.git","clone_url":"https://github.com/ENOFLAG/ENOKEY.git","svn_url":"https://github.com/ENOFLAG/ENOKEY","homepage":"","size":145,"stargazers_count":4,"watchers_count":4,"language":"Rust","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":1,"mirror_url":null,"archived":false,"open_issues_count":16,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":1,"open_issues":16,"watchers":4,"default_branch":"master"}},"base":{"label":"ENOFLAG:master","ref":"master","sha":"d1068d067b60ea64120b2462d901a7b308d99289","user":{"login":"ENOFLAG","id":29580191,"node_id":"MDEyOk9yZ2FuaXphdGlvbjI5NTgwMTkx","avatar_url":"https://avatars2.githubusercontent.com/u/29580191?v=4","gravatar_id":"","url":"https://api.github.com/users/ENOFLAG","html_url":"https://github.com/ENOFLAG","followers_url":"https://api.github.com/users/ENOFLAG/followers","following_url":"https://api.github.com/users/ENOFLAG/following{/other_user}","gists_url":"https://api.github.com/users/ENOFLAG/gists{/gist_id}","starred_url":"https://api.github.com/users/ENOFLAG/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ENOFLAG/subscriptions","organizations_url":"https://api.github.com/users/ENOFLAG/orgs","repos_url":"https://api.github.com/users/ENOFLAG/repos","events_url":"https://api.github.com/users/ENOFLAG/events{/privacy}","received_events_url":"https://api.github.com/users/ENOFLAG/received_events","type":"Organization","site_admin":false},"repo":{"id":157967251,"node_id":"MDEwOlJlcG9zaXRvcnkxNTc5NjcyNTE=","name":"ENOKEY","full_name":"ENOFLAG/ENOKEY","private":false,"owner":{"login":"ENOFLAG","id":29580191,"node_id":"MDEyOk9yZ2FuaXphdGlvbjI5NTgwMTkx","avatar_url":"https://avatars2.githubusercontent.com/u/29580191?v=4","gravatar_id":"","url":"https://api.github.com/users/ENOFLAG","html_url":"https://github.com/ENOFLAG","followers_url":"https://api.github.com/users/ENOFLAG/followers","following_url":"https://api.github.com/users/ENOFLAG/following{/other_user}","gists_url":"https://api.github.com/users/ENOFLAG/gists{/gist_id}","starred_url":"https://api.github.com/users/ENOFLAG/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ENOFLAG/subscriptions","organizations_url":"https://api.github.com/users/ENOFLAG/orgs","repos_url":"https://api.github.com/users/ENOFLAG/repos","events_url":"https://api.github.com/users/ENOFLAG/events{/privacy}","received_events_url":"https://api.github.com/users/ENOFLAG/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/ENOFLAG/ENOKEY","description":"This is the ENOKEY project for handling ssh keys","fork":false,"url":"https://api.github.com/repos/ENOFLAG/ENOKEY","forks_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/forks","keys_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/teams","hooks_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/hooks","issue_events_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/issues/events{/number}","events_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/events","assignees_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/assignees{/user}","branches_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/branches{/branch}","tags_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/tags","blobs_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/git/refs{/sha}","trees_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/statuses/{sha}","languages_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/languages","stargazers_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/stargazers","contributors_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/contributors","subscribers_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/subscribers","subscription_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/subscription","commits_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/commits{/sha}","git_commits_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/git/commits{/sha}","comments_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/comments{/number}","issue_comment_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/issues/comments{/number}","contents_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/contents/{+path}","compare_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/merges","archive_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/downloads","issues_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/issues{/number}","pulls_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/pulls{/number}","milestones_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/milestones{/number}","notifications_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/labels{/name}","releases_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/releases{/id}","deployments_url":"https://api.github.com/repos/ENOFLAG/ENOKEY/deployments","created_at":"2018-11-17T08:53:45Z","updated_at":"2018-11-18T10:42:45Z","pushed_at":"2018-11-18T10:42:52Z","git_url":"git://github.com/ENOFLAG/ENOKEY.git","ssh_url":"git@github.com:ENOFLAG/ENOKEY.git","clone_url":"https://github.com/ENOFLAG/ENOKEY.git","svn_url":"https://github.com/ENOFLAG/ENOKEY","homepage":"","size":145,"stargazers_count":4,"watchers_count":4,"language":"Rust","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":1,"mirror_url":null,"archived":false,"open_issues_count":16,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":1,"open_issues":16,"watchers":4,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/ENOFLAG/ENOKEY/pulls/2"},"html":{"href":"https://github.com/ENOFLAG/ENOKEY/pull/2"},"issue":{"href":"https://api.github.com/repos/ENOFLAG/ENOKEY/issues/2"},"comments":{"href":"https://api.github.com/repos/ENOFLAG/ENOKEY/issues/2/comments"},"review_comments":{"href":"https://api.github.com/repos/ENOFLAG/ENOKEY/pulls/2/comments"},"review_comment":{"href":"https://api.github.com/repos/ENOFLAG/ENOKEY/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ENOFLAG/ENOKEY/pulls/2/commits"},"statuses":{"href":"https://api.github.com/repos/ENOFLAG/ENOKEY/statuses/8fbd4568a7e73571fb9076859dc028245622f981"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"fsck"}}