From 5ed4a6c081e29da6600949ed2b811551e6a947f7 Mon Sep 17 00:00:00 2001 From: Blake Matthes Date: Wed, 16 Jul 2025 08:34:50 -0500 Subject: [PATCH] refactor(build): changes to show more details when we run the build stuff --- scripts/build.ps1 | 36 ++++++++++++++++++++++++++++-------- 1 file changed, 28 insertions(+), 8 deletions(-) diff --git a/scripts/build.ps1 b/scripts/build.ps1 index 83ea7fd..2fa9816 100644 --- a/scripts/build.ps1 +++ b/scripts/build.ps1 @@ -117,18 +117,38 @@ function Update-BuildNumber { dotnet publish -c Release -o ./publish Pop-Location + +try { Update-BuildNumber - + Write-Host "Zipping up the release" - npm run release:createZip - - $choice = Read-Host "Are we going to create a release? y/N" - - if ($choice -eq "y" -or $choice -eq "Y") { - npm run release:gitea $version - npm run release:publish + npm run createZip + if ($LASTEXITCODE -ne 0) { + throw "Failed to create release zip" } + $choice = Read-Host "Are we going to create a release? y/N" + if ($choice -eq "y" -or $choice -eq "Y") { + Write-Host "Creating release..." + + # This will: + # 1. Update version in package.json + # 2. Generate changelog + # 3. Create git tag + # 4. Push to remote + # 5. Create Gitea release via our script + + npm run release + if ($LASTEXITCODE -ne 0) { + throw "Failed to create Gitea release" + } + + } +} catch { + Write-Warning "Release process failed: $_" + exit 1 +} + break