Добавьте файлы проекта.

This commit is contained in:
2025-11-25 07:39:25 +03:00
parent ed6a7e1938
commit 5bbcfb1e76
21 changed files with 793 additions and 0 deletions

29
Updater/Program.cs Normal file
View File

@@ -0,0 +1,29 @@
using Updater.Core;
namespace Updater;
internal sealed class Program
{
static int Main(string[] args)
{
var logger = new ConsoleLogger();
Options? options;
try
{
options = Options.Parse(args);
}
catch (Exception ex)
{
logger.Error($"Arguments error: {ex.Message}");
Console.WriteLine(Options.Usage);
return ExitCodes.InvalidArgs;
}
var extractor = new ZipExtractor(logger);
var installer = new SafeFileInstaller(logger);
var procMgr = new ProcessManager(logger);
var app = new UpdaterApp(logger, extractor, installer, procMgr);
return app.Run(options);
}
}