SoraV2Utils/SoraV2Utils_Agent/Program.cs
krjan02 26cde137c9
Some checks failed
Build and Relase / build-release (push) Failing after 38s
Build and Relase / create-release (push) Failing after 10s
Initial commit (1.0.0)
2025-01-13 16:27:29 +01:00

34 lines
871 B
C#

using EasyPipes;
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using System.ServiceProcess;
namespace SoraV2Utils_Agent
{
internal class Program
{
static void Main(string[] args)
{
new ServiceIPC();
Server server = new Server("SoraV2UtilsNotifcation");
server.RegisterService<IToastNotification>(new NotificationSender());
server.Start();
var serviceMonitor = new ServiceMonitor("SoraV2Utils_Service");
serviceMonitor.ServiceStopped += (sender, e) =>
{
server.Stop();
System.Environment.Exit(1);
};;
var trayicon = new TrayIcon();
trayicon.Display();
}
}
}