Merge branch 'nightly' into fix/image-paths

This commit is contained in:
ReenigneArcher
2022-09-11 20:35:24 -04:00
55 changed files with 461 additions and 387 deletions

View File

@@ -1,7 +1,10 @@
@echo off
rem Get sunshine root directory
for %%I in ("%~dp0\..") do set "ROOT_DIR=%%~fI"
set RULE_NAME=Sunshine
set PROGRAM_BIN="%~dp0sunshine.exe"
set PROGRAM_BIN="%ROOT_DIR%\sunshine.exe"
rem Add the rule
netsh advfirewall firewall add rule name=%RULE_NAME% dir=in action=allow protocol=tcp program=%PROGRAM_BIN% enable=yes

View File

@@ -0,0 +1,27 @@
@echo off
rem Get sunshine root directory
for %%I in ("%~dp0\..") do set "ROOT_DIR=%%~fI"
set SERVICE_NAME=sunshinesvc
set SERVICE_BIN="%ROOT_DIR%\tools\sunshinesvc.exe"
set SERVICE_START_TYPE=auto
rem Check if sunshinesvc already exists
sc qc %SERVICE_NAME% > nul 2>&1
if %ERRORLEVEL%==0 (
rem Stop the existing service if running
net stop %SERVICE_NAME%
rem Reconfigure the existing service
set SC_CMD=config
) else (
rem Create a new service
set SC_CMD=create
)
rem Run the sc command to create/reconfigure the service
sc %SC_CMD% %SERVICE_NAME% binPath= %SERVICE_BIN% start= %SERVICE_START_TYPE%
rem Start the new service
net start %SERVICE_NAME%

View File

@@ -0,0 +1,7 @@
@echo off
set SERVICE_NAME=sunshinesvc
net stop %SERVICE_NAME%
sc delete %SERVICE_NAME%