private async void CreateRepo_Click(object sender, RoutedEventArgs e)
        {
            CreateRepo.IsEnabled = false;
            RepoProgress.Visibility = Visibility.Visible;

            var asd = new List<string>();
            foreach (CheckBox item in ListOfFolders.Items)
            {
                if (item.IsChecked.HasValue)
                {
                    if ((bool)item.IsChecked) asd.Add((string)item.Content);
                }
            }

            if (asd.Count > 0)
            {
                await Task.Run(() =>
                {
                    var newRepo = new RepositoryData();
                    newRepo.DownloadRoot = Repository.DefaultUrlBase;

                    newRepo.Files = r.CreateRepositoryData(asd.AsEnumerable());
                    string output = JsonConvert.SerializeObject(newRepo);

                    try
                    {
                        using (var wr = new StreamWriter("updater.json", false))
                        {
                            wr.Write(output);
                            wr.Flush();
                        }
                        MessageBox.Show("Metadata created successfully.");
                    }
                    catch (Exception)
                    {
                        MessageBox.Show("Unable to write metadata file.");
                    }
                });
            }

            CreateRepo.IsEnabled = true;
            RepoProgress.Visibility = Visibility.Hidden;
        }
        public Task LoadData()
        {
            Task t = Task.Run(() =>
            {
                ProgressFile = "Downloading repository information...";
                WebRequest request = WebRequest.Create(_url);
                WebResponse response = request.GetResponse();
                Stream rs = response.GetResponseStream();
                string value = new StreamReader(rs).ReadToEnd();
                rs.Close();
                data = JsonConvert.DeserializeObject<RepositoryData>(value);

                GetChangedFiles();
                GetFilesToPrune();
                ProgressFile = string.Format("Pending {0} changes", IncomingChanges.Count + PruneChanges.Count);
            });
            return t;
        }