Files
Bubberstation/tools/bootstrap/node.bat
SkyratBot 98baf80ecf [MIRROR] Exit on DreamMaker warnings in CI Windows build + Tools reset (#7784)
* Exit on DreamMaker warnings in CI Windows build

* a

* AAAAAAAAAAAAAAAAA

* AAAAAA

* F

* a

* Update .github/gbp.toml

* Update .github/gbp.toml

* Update .github/gbp.toml

* Update .github/gbp.toml

Co-authored-by: mokulus <36231852+mokulus@users.noreply.github.com>
Co-authored-by: Gandalf <jzo123@hotmail.com>
2021-09-01 16:41:46 +01:00

27 lines
758 B
Batchfile

@echo off
where node.exe >nul 2>nul
if %errorlevel% == 0 (
echo | set /p printed_str="Using system-wide Node "
call node.exe --version
call node.exe %*
goto exit_with_last_error_level
)
call powershell -NoLogo -ExecutionPolicy Bypass -File "%~dp0\node_.ps1" Download-Node
for /f "tokens=* USEBACKQ" %%s in (`
call powershell -NoLogo -ExecutionPolicy Bypass -File "%~dp0\node_.ps1" Get-Path
`) do (
set "PATH=%%s;%PATH%"
)
where node.exe >nul 2>nul
if %errorlevel% == 0 (
echo | set /p printed_str="Using vendored Node "
call node.exe --version
call node.exe %*
goto exit_with_last_error_level
)
echo "node.bat: Failed to bootstrap Node!"
%COMSPEC% /c exit 1
:exit_with_last_error_level
if not %errorlevel% == 0 %COMSPEC% /c exit %errorlevel% >nul