- Enhanced isometric_controls_tests.cpp to include assertions for controller fire attempt suppression under various conditions. - Added tests for the Usecode interpreter in usecode_vm_tests.cpp, verifying script execution and stack manipulation. - Introduced a new PowerShell script, clean-old-build-artifacts.ps1, to facilitate the cleanup of old build artifacts in specified directories.
44 lines
1.3 KiB
Batchfile
44 lines
1.3 KiB
Batchfile
@echo off
|
|
setlocal
|
|
|
|
set "CONFIG=%~1"
|
|
if "%CONFIG%"=="" set "CONFIG=Debug"
|
|
|
|
set "REPO_ROOT=%~dp0..\.."
|
|
for %%I in ("%REPO_ROOT%") do set "REPO_ROOT=%%~fI"
|
|
|
|
set "VSWHERE=%ProgramFiles(x86)%\Microsoft Visual Studio\Installer\vswhere.exe"
|
|
if not exist "%VSWHERE%" (
|
|
echo vswhere.exe was not found at "%VSWHERE%".
|
|
exit /b 2
|
|
)
|
|
|
|
for /f "usebackq delims=" %%I in (`"%VSWHERE%" -latest -products * -requires Microsoft.VisualStudio.Component.VC.Tools.x86.x64 -property installationPath`) do set "VSINSTALL=%%I"
|
|
|
|
if "%VSINSTALL%"=="" (
|
|
echo Visual Studio with MSVC x64 tools was not found.
|
|
exit /b 2
|
|
)
|
|
|
|
set "VCVARS=%VSINSTALL%\VC\Auxiliary\Build\vcvars64.bat"
|
|
if not exist "%VCVARS%" (
|
|
echo vcvars64.bat was not found at "%VCVARS%".
|
|
exit /b 2
|
|
)
|
|
|
|
call "%VCVARS%" || exit /b 2
|
|
|
|
cd /d "%REPO_ROOT%" || exit /b 2
|
|
|
|
set "BUILD_DIR=rebuild/remorse/out/build"
|
|
cmake -S rebuild/remorse -B "%BUILD_DIR%" -DCMAKE_GENERATOR_INSTANCE="%VSINSTALL%" || exit /b 1
|
|
cmake --build "%BUILD_DIR%" --config "%CONFIG%" || exit /b 1
|
|
ctest --test-dir "%BUILD_DIR%" -C "%CONFIG%" --output-on-failure || exit /b 1
|
|
|
|
set "EXE=%BUILD_DIR%\%CONFIG%\remorse_rebuild.exe"
|
|
if not exist "%EXE%" (
|
|
echo Built executable was not found at "%EXE%".
|
|
exit /b 1
|
|
)
|
|
|
|
"%EXE%" exports\src_remorse\export_manifest.json || exit /b 1
|