Skip to content

Commit e5e2569

Browse files
publish
1 parent a6d5270 commit e5e2569

1 file changed

Lines changed: 6 additions & 2 deletions

File tree

build/build.ps1

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -243,5 +243,9 @@ Write-Host "Zip structure: dbatools.library.zip contains 'dbatools.library' fold
243243
Write-Host "For testing: Extract to a folder in `$env:PSModulePath or use Install-DbatoolsLibrary.ps1"
244244
Write-Host "Build completed successfully. Files organized and temporary artifacts cleaned up."
245245

246-
Write-Warning $LASTEXITCODE
247-
$LASTEXITCODE = 0
246+
# if github actions and lastexitcode =0 then exit with success
247+
if ($env:GITHUB_ACTIONS -and $LASTEXITCODE -eq 0) {
248+
exit 0
249+
} else {
250+
exit $LASTEXITCODE
251+
}

0 commit comments

Comments
 (0)