Various PR merging improvements

This commit is contained in:
Cyberboss
2017-11-30 10:45:31 -05:00
parent 4e10b53b83
commit 96ad0afdc5
3 changed files with 25 additions and 13 deletions
+8 -3
View File
@@ -2,6 +2,7 @@ using Octokit;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Reflection;
using System.Threading.Tasks;
using System.Windows.Forms;
@@ -365,9 +366,13 @@ namespace TGS.ControlPanel
var mergeResults = await Task.Factory.StartNew(() => repo.MergePullRequests(pulls, true));
var compileStartResult = await Task.Factory.StartNew(() => Interface.GetComponent<ITGCompiler>().Compile(true));
foreach (var I in mergeResults)
if (I != null)
MessageBox.Show(res, "Error Re-merging Pull Request");
//Show any errors
for (var I = 0; I < mergeResults.Count(); ++I)
{
var err = mergeResults.ElementAt(I);
if (err != null)
MessageBox.Show(err, String.Format("Error re-merging PR #{0}", pulls[I].Number));
}
if (!compileStartResult)
MessageBox.Show(res, "Error starting compile!");