mirror of
https://github.com/tgstation/tgstation-server.git
synced 2026-08-30 00:22:40 +01:00
TGS3 (#3)
Let's just get this merged instead of having a massive PR Original PR: tgstation/tgstation#26534
This commit is contained in:
@@ -0,0 +1,28 @@
|
||||
using System.ComponentModel;
|
||||
using System.Configuration.Install;
|
||||
using System.ServiceProcess;
|
||||
|
||||
namespace ServerService
|
||||
{
|
||||
[RunInstaller(true)]
|
||||
public partial class ProjectInstaller : Installer
|
||||
{
|
||||
public ProjectInstaller()
|
||||
{
|
||||
InitializeComponent();
|
||||
serviceInstaller1.BeforeUninstall += ServiceInstaller1_BeforeUninstall;
|
||||
}
|
||||
|
||||
private void ServiceInstaller1_BeforeUninstall(object sender, InstallEventArgs e)
|
||||
{
|
||||
}
|
||||
|
||||
private void ServiceInstaller1_AfterInstall(object sender, InstallEventArgs e)
|
||||
{
|
||||
using (ServiceController sc = new ServiceController(serviceInstaller1.ServiceName))
|
||||
{
|
||||
sc.Start();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user