{"action":"created","comment":{"url":"https://api.github.com/repos/highfidelity/hifi/pulls/comments/32147013","id":32147013,"diff_hunk":"@@ -0,0 +1,76 @@\n+//\n+//  AutoUpdate.h\n+//  libraries/auto-update/src\n+//\n+//  Created by Leonardo Murillo on 6/1/2015.\n+//  Copyright 2015 High Fidelity, Inc.\n+//\n+//\n+//\n+//  Distributed under the Apache License, Version 2.0.\n+//  See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html\n+//\n+\n+#ifndef __hifi__AutoUpdate__\n+#define __hifi__AutoUpdate__\n+\n+#include <QtCore/QObject>\n+#include <QtCore/QSettings>\n+#include <QtCore/QCoreApplication>\n+#include <QDesktopServices>\n+#include <QDebug>\n+#include <QString>\n+#include <QUrl>\n+#include <QMap>\n+#include <QNetworkRequest>\n+#include <QNetworkReply>\n+#include <QNetworkConfiguration>\n+#include <QNetworkAccessManager>\n+#include <QXmlStreamReader>\n+#include <QXmlStreamAttributes>\n+\n+#include <DependencyManager.h>\n+\n+\n+const QUrl BUILDS_XML_URL(\"https://highfidelity.com/builds.xml\");\n+\n+class AutoUpdate : public QObject, public Dependency {\n+    Q_OBJECT\n+    SINGLETON_DEPENDENCY\n+    \n+public:\n+    // Methods\n+    AutoUpdate();\n+    \n+    void checkForUpdate();\n+    QMap<int, QMap<QString, QString>> &getBuildData() { return *_builds; }\n+    void performAutoUpdate(int version);\n+    \n+public slots:","path":"libraries/auto-update/src/AutoUpdate.h","position":49,"original_position":49,"commit_id":"1d785c714b52498d9377bebc2e80eabcc008a34f","original_commit_id":"1d785c714b52498d9377bebc2e80eabcc008a34f","user":{"login":"birarda","id":724069,"avatar_url":"https://avatars.githubusercontent.com/u/724069?v=3","gravatar_id":"","url":"https://api.github.com/users/birarda","html_url":"https://github.com/birarda","followers_url":"https://api.github.com/users/birarda/followers","following_url":"https://api.github.com/users/birarda/following{/other_user}","gists_url":"https://api.github.com/users/birarda/gists{/gist_id}","starred_url":"https://api.github.com/users/birarda/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/birarda/subscriptions","organizations_url":"https://api.github.com/users/birarda/orgs","repos_url":"https://api.github.com/users/birarda/repos","events_url":"https://api.github.com/users/birarda/events{/privacy}","received_events_url":"https://api.github.com/users/birarda/received_events","type":"User","site_admin":false},"body":"remove this block if it's not used\r\n","created_at":"2015-06-10T18:03:07Z","updated_at":"2015-06-10T18:03:07Z","html_url":"https://github.com/highfidelity/hifi/pull/5082#discussion_r32147013","pull_request_url":"https://api.github.com/repos/highfidelity/hifi/pulls/5082","_links":{"self":{"href":"https://api.github.com/repos/highfidelity/hifi/pulls/comments/32147013"},"html":{"href":"https://github.com/highfidelity/hifi/pull/5082#discussion_r32147013"},"pull_request":{"href":"https://api.github.com/repos/highfidelity/hifi/pulls/5082"}}},"pull_request":{"url":"https://api.github.com/repos/highfidelity/hifi/pulls/5082","id":37195740,"html_url":"https://github.com/highfidelity/hifi/pull/5082","diff_url":"https://github.com/highfidelity/hifi/pull/5082.diff","patch_url":"https://github.com/highfidelity/hifi/pull/5082.patch","issue_url":"https://api.github.com/repos/highfidelity/hifi/issues/5082","number":5082,"state":"open","locked":false,"title":"Checkpoint towards auto updater","user":{"login":"murillodigital","id":1219288,"avatar_url":"https://avatars.githubusercontent.com/u/1219288?v=3","gravatar_id":"","url":"https://api.github.com/users/murillodigital","html_url":"https://github.com/murillodigital","followers_url":"https://api.github.com/users/murillodigital/followers","following_url":"https://api.github.com/users/murillodigital/following{/other_user}","gists_url":"https://api.github.com/users/murillodigital/gists{/gist_id}","starred_url":"https://api.github.com/users/murillodigital/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/murillodigital/subscriptions","organizations_url":"https://api.github.com/users/murillodigital/orgs","repos_url":"https://api.github.com/users/murillodigital/repos","events_url":"https://api.github.com/users/murillodigital/events{/privacy}","received_events_url":"https://api.github.com/users/murillodigital/received_events","type":"User","site_admin":false},"body":"This is the first step towards a really smart auto updater:\r\n\r\n1) AutoUpdate is now an individual library, that works as a dependency singleton\r\n2) AutoUpdate now uses builds.xml and not latestVersion.xml for its versioning data - we can now deprecate latestVersion.xml.\r\n4) AutoUpdate stores all build information in a QMap\r\n5) UpdateDialog is now QML and display release notes, release time and how many versions the user is behind.\r\n\r\n@jherico can you please take a look to see if things look right on the QML side.","created_at":"2015-06-08T21:03:55Z","updated_at":"2015-06-10T18:03:07Z","closed_at":null,"merged_at":null,"merge_commit_sha":"55810392d9e650f5b6fde3c181cf70560ac6393c","assignee":{"login":"birarda","id":724069,"avatar_url":"https://avatars.githubusercontent.com/u/724069?v=3","gravatar_id":"","url":"https://api.github.com/users/birarda","html_url":"https://github.com/birarda","followers_url":"https://api.github.com/users/birarda/followers","following_url":"https://api.github.com/users/birarda/following{/other_user}","gists_url":"https://api.github.com/users/birarda/gists{/gist_id}","starred_url":"https://api.github.com/users/birarda/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/birarda/subscriptions","organizations_url":"https://api.github.com/users/birarda/orgs","repos_url":"https://api.github.com/users/birarda/repos","events_url":"https://api.github.com/users/birarda/events{/privacy}","received_events_url":"https://api.github.com/users/birarda/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/highfidelity/hifi/pulls/5082/commits","review_comments_url":"https://api.github.com/repos/highfidelity/hifi/pulls/5082/comments","review_comment_url":"https://api.github.com/repos/highfidelity/hifi/pulls/comments{/number}","comments_url":"https://api.github.com/repos/highfidelity/hifi/issues/5082/comments","statuses_url":"https://api.github.com/repos/highfidelity/hifi/statuses/1d785c714b52498d9377bebc2e80eabcc008a34f","head":{"label":"murillodigital:auto-updater","ref":"auto-updater","sha":"1d785c714b52498d9377bebc2e80eabcc008a34f","user":{"login":"murillodigital","id":1219288,"avatar_url":"https://avatars.githubusercontent.com/u/1219288?v=3","gravatar_id":"","url":"https://api.github.com/users/murillodigital","html_url":"https://github.com/murillodigital","followers_url":"https://api.github.com/users/murillodigital/followers","following_url":"https://api.github.com/users/murillodigital/following{/other_user}","gists_url":"https://api.github.com/users/murillodigital/gists{/gist_id}","starred_url":"https://api.github.com/users/murillodigital/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/murillodigital/subscriptions","organizations_url":"https://api.github.com/users/murillodigital/orgs","repos_url":"https://api.github.com/users/murillodigital/repos","events_url":"https://api.github.com/users/murillodigital/events{/privacy}","received_events_url":"https://api.github.com/users/murillodigital/received_events","type":"User","site_admin":false},"repo":{"id":35686229,"name":"hifi","full_name":"murillodigital/hifi","owner":{"login":"murillodigital","id":1219288,"avatar_url":"https://avatars.githubusercontent.com/u/1219288?v=3","gravatar_id":"","url":"https://api.github.com/users/murillodigital","html_url":"https://github.com/murillodigital","followers_url":"https://api.github.com/users/murillodigital/followers","following_url":"https://api.github.com/users/murillodigital/following{/other_user}","gists_url":"https://api.github.com/users/murillodigital/gists{/gist_id}","starred_url":"https://api.github.com/users/murillodigital/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/murillodigital/subscriptions","organizations_url":"https://api.github.com/users/murillodigital/orgs","repos_url":"https://api.github.com/users/murillodigital/repos","events_url":"https://api.github.com/users/murillodigital/events{/privacy}","received_events_url":"https://api.github.com/users/murillodigital/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/murillodigital/hifi","description":"Open source software for shared virtual worlds using HMDs and dynamically assigned devices as servers.  San Francisco based startup, we are hiring: http://highfidelity.com/jobs  Documentation at http://docs.highfidelity.com  Contribute by reporting bugs & doing jobs on http://worklist.net","fork":true,"url":"https://api.github.com/repos/murillodigital/hifi","forks_url":"https://api.github.com/repos/murillodigital/hifi/forks","keys_url":"https://api.github.com/repos/murillodigital/hifi/keys{/key_id}","collaborators_url":"https://api.github.com/repos/murillodigital/hifi/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/murillodigital/hifi/teams","hooks_url":"https://api.github.com/repos/murillodigital/hifi/hooks","issue_events_url":"https://api.github.com/repos/murillodigital/hifi/issues/events{/number}","events_url":"https://api.github.com/repos/murillodigital/hifi/events","assignees_url":"https://api.github.com/repos/murillodigital/hifi/assignees{/user}","branches_url":"https://api.github.com/repos/murillodigital/hifi/branches{/branch}","tags_url":"https://api.github.com/repos/murillodigital/hifi/tags","blobs_url":"https://api.github.com/repos/murillodigital/hifi/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/murillodigital/hifi/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/murillodigital/hifi/git/refs{/sha}","trees_url":"https://api.github.com/repos/murillodigital/hifi/git/trees{/sha}","statuses_url":"https://api.github.com/repos/murillodigital/hifi/statuses/{sha}","languages_url":"https://api.github.com/repos/murillodigital/hifi/languages","stargazers_url":"https://api.github.com/repos/murillodigital/hifi/stargazers","contributors_url":"https://api.github.com/repos/murillodigital/hifi/contributors","subscribers_url":"https://api.github.com/repos/murillodigital/hifi/subscribers","subscription_url":"https://api.github.com/repos/murillodigital/hifi/subscription","commits_url":"https://api.github.com/repos/murillodigital/hifi/commits{/sha}","git_commits_url":"https://api.github.com/repos/murillodigital/hifi/git/commits{/sha}","comments_url":"https://api.github.com/repos/murillodigital/hifi/comments{/number}","issue_comment_url":"https://api.github.com/repos/murillodigital/hifi/issues/comments{/number}","contents_url":"https://api.github.com/repos/murillodigital/hifi/contents/{+path}","compare_url":"https://api.github.com/repos/murillodigital/hifi/compare/{base}...{head}","merges_url":"https://api.github.com/repos/murillodigital/hifi/merges","archive_url":"https://api.github.com/repos/murillodigital/hifi/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/murillodigital/hifi/downloads","issues_url":"https://api.github.com/repos/murillodigital/hifi/issues{/number}","pulls_url":"https://api.github.com/repos/murillodigital/hifi/pulls{/number}","milestones_url":"https://api.github.com/repos/murillodigital/hifi/milestones{/number}","notifications_url":"https://api.github.com/repos/murillodigital/hifi/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/murillodigital/hifi/labels{/name}","releases_url":"https://api.github.com/repos/murillodigital/hifi/releases{/id}","created_at":"2015-05-15T17:06:27Z","updated_at":"2015-05-15T17:06:32Z","pushed_at":"2015-06-09T15:02:01Z","git_url":"git://github.com/murillodigital/hifi.git","ssh_url":"git@github.com:murillodigital/hifi.git","clone_url":"https://github.com/murillodigital/hifi.git","svn_url":"https://github.com/murillodigital/hifi","homepage":"","size":158200,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":false,"has_downloads":true,"has_wiki":false,"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":"highfidelity:master","ref":"master","sha":"759a4a323ba7bde875478f06bed1f8de8347db90","user":{"login":"highfidelity","id":1565370,"avatar_url":"https://avatars.githubusercontent.com/u/1565370?v=3","gravatar_id":"","url":"https://api.github.com/users/highfidelity","html_url":"https://github.com/highfidelity","followers_url":"https://api.github.com/users/highfidelity/followers","following_url":"https://api.github.com/users/highfidelity/following{/other_user}","gists_url":"https://api.github.com/users/highfidelity/gists{/gist_id}","starred_url":"https://api.github.com/users/highfidelity/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/highfidelity/subscriptions","organizations_url":"https://api.github.com/users/highfidelity/orgs","repos_url":"https://api.github.com/users/highfidelity/repos","events_url":"https://api.github.com/users/highfidelity/events{/privacy}","received_events_url":"https://api.github.com/users/highfidelity/received_events","type":"Organization","site_admin":false},"repo":{"id":5372872,"name":"hifi","full_name":"highfidelity/hifi","owner":{"login":"highfidelity","id":1565370,"avatar_url":"https://avatars.githubusercontent.com/u/1565370?v=3","gravatar_id":"","url":"https://api.github.com/users/highfidelity","html_url":"https://github.com/highfidelity","followers_url":"https://api.github.com/users/highfidelity/followers","following_url":"https://api.github.com/users/highfidelity/following{/other_user}","gists_url":"https://api.github.com/users/highfidelity/gists{/gist_id}","starred_url":"https://api.github.com/users/highfidelity/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/highfidelity/subscriptions","organizations_url":"https://api.github.com/users/highfidelity/orgs","repos_url":"https://api.github.com/users/highfidelity/repos","events_url":"https://api.github.com/users/highfidelity/events{/privacy}","received_events_url":"https://api.github.com/users/highfidelity/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/highfidelity/hifi","description":"Open source software for shared virtual worlds using HMDs and dynamically assigned devices as servers.  San Francisco based startup, we are hiring: http://highfidelity.com/jobs  Documentation at http://docs.highfidelity.com  Contribute by reporting bugs & doing jobs on http://worklist.net","fork":false,"url":"https://api.github.com/repos/highfidelity/hifi","forks_url":"https://api.github.com/repos/highfidelity/hifi/forks","keys_url":"https://api.github.com/repos/highfidelity/hifi/keys{/key_id}","collaborators_url":"https://api.github.com/repos/highfidelity/hifi/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/highfidelity/hifi/teams","hooks_url":"https://api.github.com/repos/highfidelity/hifi/hooks","issue_events_url":"https://api.github.com/repos/highfidelity/hifi/issues/events{/number}","events_url":"https://api.github.com/repos/highfidelity/hifi/events","assignees_url":"https://api.github.com/repos/highfidelity/hifi/assignees{/user}","branches_url":"https://api.github.com/repos/highfidelity/hifi/branches{/branch}","tags_url":"https://api.github.com/repos/highfidelity/hifi/tags","blobs_url":"https://api.github.com/repos/highfidelity/hifi/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/highfidelity/hifi/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/highfidelity/hifi/git/refs{/sha}","trees_url":"https://api.github.com/repos/highfidelity/hifi/git/trees{/sha}","statuses_url":"https://api.github.com/repos/highfidelity/hifi/statuses/{sha}","languages_url":"https://api.github.com/repos/highfidelity/hifi/languages","stargazers_url":"https://api.github.com/repos/highfidelity/hifi/stargazers","contributors_url":"https://api.github.com/repos/highfidelity/hifi/contributors","subscribers_url":"https://api.github.com/repos/highfidelity/hifi/subscribers","subscription_url":"https://api.github.com/repos/highfidelity/hifi/subscription","commits_url":"https://api.github.com/repos/highfidelity/hifi/commits{/sha}","git_commits_url":"https://api.github.com/repos/highfidelity/hifi/git/commits{/sha}","comments_url":"https://api.github.com/repos/highfidelity/hifi/comments{/number}","issue_comment_url":"https://api.github.com/repos/highfidelity/hifi/issues/comments{/number}","contents_url":"https://api.github.com/repos/highfidelity/hifi/contents/{+path}","compare_url":"https://api.github.com/repos/highfidelity/hifi/compare/{base}...{head}","merges_url":"https://api.github.com/repos/highfidelity/hifi/merges","archive_url":"https://api.github.com/repos/highfidelity/hifi/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/highfidelity/hifi/downloads","issues_url":"https://api.github.com/repos/highfidelity/hifi/issues{/number}","pulls_url":"https://api.github.com/repos/highfidelity/hifi/pulls{/number}","milestones_url":"https://api.github.com/repos/highfidelity/hifi/milestones{/number}","notifications_url":"https://api.github.com/repos/highfidelity/hifi/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/highfidelity/hifi/labels{/name}","releases_url":"https://api.github.com/repos/highfidelity/hifi/releases{/id}","created_at":"2012-08-10T18:26:22Z","updated_at":"2015-06-10T15:33:49Z","pushed_at":"2015-06-10T17:12:58Z","git_url":"git://github.com/highfidelity/hifi.git","ssh_url":"git@github.com:highfidelity/hifi.git","clone_url":"https://github.com/highfidelity/hifi.git","svn_url":"https://github.com/highfidelity/hifi","homepage":"","size":210789,"stargazers_count":274,"watchers_count":274,"language":"C++","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":156,"mirror_url":null,"open_issues_count":54,"forks":156,"open_issues":54,"watchers":274,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/highfidelity/hifi/pulls/5082"},"html":{"href":"https://github.com/highfidelity/hifi/pull/5082"},"issue":{"href":"https://api.github.com/repos/highfidelity/hifi/issues/5082"},"comments":{"href":"https://api.github.com/repos/highfidelity/hifi/issues/5082/comments"},"review_comments":{"href":"https://api.github.com/repos/highfidelity/hifi/pulls/5082/comments"},"review_comment":{"href":"https://api.github.com/repos/highfidelity/hifi/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/highfidelity/hifi/pulls/5082/commits"},"statuses":{"href":"https://api.github.com/repos/highfidelity/hifi/statuses/1d785c714b52498d9377bebc2e80eabcc008a34f"}}}}