diff options
| author | Bradley Lewis <22850972+BradLewis@users.noreply.github.com> | 2025-10-11 20:00:29 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-10-11 20:00:29 -0400 |
| commit | 3e9dc7f8353edd0ef389005fbf98a900e8007b6c (patch) | |
| tree | daa46fa8ee9d867b28ecab7b24693a986db9aad9 /ci.bat | |
| parent | ed91e4409c4605baa58d3ab333d9d093a112212c (diff) | |
| parent | 617bd092c14e4cf997d99eea9d9ad2c5ce12e8af (diff) | |
Merge pull request #1088 from BradLewis/feat/create-releasesdev-2025-09
Update nightly release action to allow creating releases tied to odin versions
Diffstat (limited to 'ci.bat')
| -rw-r--r-- | ci.bat | 13 |
1 files changed, 7 insertions, 6 deletions
@@ -2,20 +2,21 @@ setlocal enabledelayedexpansion -for /f %%a in ('git rev-parse --short HEAD 2^>NUL') do set commit_hash=%%a -for /f %%d in ('powershell -command "[DateTime]::UtcNow.ToString('yyyy-MM-dd')"') do set today=%%d -set version=nightly-%today%-%commit_hash% - +if not defined OLS_VERSION ( + for /f %%a in ('git rev-parse --short HEAD 2^>NUL') do set commit_hash=%%a + for /f %%d in ('powershell -command "[DateTime]::UtcNow.ToString('yyyy-MM-dd')"') do set today=%%d + set "OLS_VERSION=nightly-!today!-!commit_hash!" +) if "%1" == "CI" ( set "PATH=%cd%\Odin;!PATH!" odin test tests -collection:src=src -define:ODIN_TEST_THREADS=1 if %errorlevel% neq 0 exit /b 1 - odin build src\ -collection:src=src -out:ols.exe -o:speed -no-bounds-check -extra-linker-flags:"/STACK:4000000,2000000" -define:VERSION=%version% + odin build src\ -collection:src=src -out:ols.exe -o:speed -no-bounds-check -extra-linker-flags:"/STACK:4000000,2000000" -define:VERSION=%OLS_VERSION% call "tools/odinfmt/tests.bat" if %errorlevel% neq 0 exit /b 1 ) else ( - odin build src\ -collection:src=src -out:ols.exe -o:speed -no-bounds-check -extra-linker-flags:"/STACK:4000000,2000000" -define:VERSION=%version% + odin build src\ -collection:src=src -out:ols.exe -o:speed -no-bounds-check -extra-linker-flags:"/STACK:4000000,2000000" -define:VERSION=%OLS_VERSION% ) |