@echo off
setlocal
net session >nul 2>&1
if not %errorlevel%==0 (
  echo Please right-click Install-Agent.bat and choose Run as administrator.
  pause
  exit /b 1
)
powershell.exe -NoProfile -ExecutionPolicy Bypass -File "%~dp0Install-Agent.ps1"
exit /b %errorlevel%
