added installer
This commit is contained in:
parent
1d04e2a4e8
commit
ce741133d8
12 changed files with 2226 additions and 0 deletions
36
Installer/update.bat
Normal file
36
Installer/update.bat
Normal file
|
|
@ -0,0 +1,36 @@
|
|||
@echo off
|
||||
REM GSP Windows Agent Update Script
|
||||
REM This script updates an existing Git-managed agent installation
|
||||
|
||||
setlocal enabledelayedexpansion
|
||||
|
||||
REM Check for Administrator privileges
|
||||
net session >nul 2>&1
|
||||
if %errorlevel% neq 0 (
|
||||
echo.
|
||||
echo ERROR: This updater must be run as Administrator.
|
||||
echo.
|
||||
echo Please:
|
||||
echo 1. Right-click this batch file
|
||||
echo 2. Select "Run as Administrator"
|
||||
echo 3. Click "Yes" when prompted
|
||||
echo.
|
||||
pause
|
||||
exit /b 1
|
||||
)
|
||||
|
||||
REM Get the directory where this batch file is located
|
||||
set "SCRIPT_DIR=%~dp0"
|
||||
|
||||
REM Verify the PowerShell script exists
|
||||
if not exist "%SCRIPT_DIR%Update-GSP-WindowsAgent.ps1" (
|
||||
echo ERROR: Update-GSP-WindowsAgent.ps1 not found in %SCRIPT_DIR%
|
||||
pause
|
||||
exit /b 1
|
||||
)
|
||||
|
||||
REM Launch the PowerShell updater
|
||||
powershell.exe -NoProfile -ExecutionPolicy Bypass -Command "& '%SCRIPT_DIR%Update-GSP-WindowsAgent.ps1'" %*
|
||||
|
||||
REM Exit with PowerShell's exit code
|
||||
exit /b %ERRORLEVEL%
|
||||
Loading…
Add table
Add a link
Reference in a new issue