fixes
This commit is contained in:
@@ -144,7 +144,10 @@ public partial class Form1
|
|||||||
|
|
||||||
private async Task ExecuteUpdate(bool doInstall)
|
private async Task ExecuteUpdate(bool doInstall)
|
||||||
{
|
{
|
||||||
var updater = new ModpackInstaller(updateConfig, modpackInfo);
|
var updater = new ModpackInstaller(updateConfig, modpackInfo)
|
||||||
|
{
|
||||||
|
OverwriteRefTag = Program.Options.RefTag
|
||||||
|
};
|
||||||
updater.InstallProgessUpdated += Update_InstallProgessUpdated;
|
updater.InstallProgessUpdated += Update_InstallProgessUpdated;
|
||||||
updater.CheckingProgressUpdated += Updated_CheckingProgresssUpdated;
|
updater.CheckingProgressUpdated += Updated_CheckingProgresssUpdated;
|
||||||
|
|
||||||
|
|||||||
@@ -18,6 +18,8 @@ public static class Program
|
|||||||
|
|
||||||
public static ILogger Log => log;
|
public static ILogger Log => log;
|
||||||
|
|
||||||
|
internal static Options Options { get; private set; }
|
||||||
|
|
||||||
[DllImport("kernel32.dll")]
|
[DllImport("kernel32.dll")]
|
||||||
static extern nint GetConsoleWindow();
|
static extern nint GetConsoleWindow();
|
||||||
|
|
||||||
@@ -33,15 +35,15 @@ public static class Program
|
|||||||
[STAThread]
|
[STAThread]
|
||||||
internal static void Main(string[] args)
|
internal static void Main(string[] args)
|
||||||
{
|
{
|
||||||
var options = new Options(args);
|
Options = new Options(args);
|
||||||
if (options.Help)
|
if (Options.Help)
|
||||||
options.DrawHelp();
|
Options.DrawHelp();
|
||||||
else if (options.NoUi)
|
else if (Options.NoUi)
|
||||||
InstallWithoutGui(options.UpdateOptions, options.Silent);
|
InstallWithoutGui(Options.UpdateOptions, Options.Silent);
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
ShowWindow(GetConsoleWindow(), 0);
|
ShowWindow(GetConsoleWindow(), 0);
|
||||||
RunApp(options.UpdateOptions);
|
RunApp(Options.UpdateOptions);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -103,6 +105,7 @@ public static class Program
|
|||||||
// Check for update
|
// Check for update
|
||||||
var installer = new ModpackInstaller(config, info)
|
var installer = new ModpackInstaller(config, info)
|
||||||
{
|
{
|
||||||
|
OverwriteRefTag = Options.RefTag,
|
||||||
Log = Log,
|
Log = Log,
|
||||||
};
|
};
|
||||||
var result = installer.Check(updateOptions).Result;
|
var result = installer.Check(updateOptions).Result;
|
||||||
|
|||||||
Reference in New Issue
Block a user