Skip to content

Commit 155af59

Browse files
committed
Build script update (#5869)
1 parent 7682b68 commit 155af59

File tree

2 files changed

+18
-4
lines changed

2 files changed

+18
-4
lines changed

build.ps1

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -248,8 +248,20 @@ function CreateZips([string] $runtimeSuffix) {
248248
}
249249

250250
function deleteDuplicateWorkers() {
251-
Write-Host "Deleting workers directory: $privateSiteExtensionPath\32bit\workers"
252-
Remove-Item -Recurse -Force "$privateSiteExtensionPath\32bit\workers" -ErrorAction SilentlyContinue
251+
if(Test-Path "$privateSiteExtensionPath\64bit\workers") {
252+
Write-Host "Moving workers directory:$privateSiteExtensionPath\64bit\workers to" $privateSiteExtensionPath
253+
Move-Item -Path "$privateSiteExtensionPath\64bit\workers" -Destination "$privateSiteExtensionPath\workers"
254+
255+
Write-Host "Silently removing $privateSiteExtensionPath\32bit\workers if exists"
256+
Remove-Item -Recurse -Force "$privateSiteExtensionPath\32bit\workers" -ErrorAction SilentlyContinue
257+
}
258+
elseif(Test-Path "$privateSiteExtensionPath\32bit\workers") {
259+
Write-Host "Moving workers directory:$privateSiteExtensionPath\32bit\workers to" $privateSiteExtensionPath
260+
Move-Item -Path "$privateSiteExtensionPath\32bit\workers" -Destination "$privateSiteExtensionPath\workers"
261+
262+
Write-Host "Silently removing $privateSiteExtensionPath\64bit\workers if exists"
263+
Remove-Item -Recurse -Force "$privateSiteExtensionPath\64bit\workers" -ErrorAction SilentlyContinue
264+
}
253265
}
254266

255267
function cleanExtension([string] $bitness) {

build/initialize-pipeline.ps1

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,11 @@ $bypassPackaging = $true
44
$includeSuffix = $true
55
Write-Host "SourceBranch: $sourceBranch, Build reason: $buildReason"
66

7-
if($sourceBranch.endsWith('master') -and ($buildReason -ne "PullRequest"))
7+
if(($sourceBranch.endsWith('master') -or $sourceBranch.endsWith('dev')) -and ($buildReason -ne "PullRequest"))
88
{
9-
$includeSuffix = $false
9+
if($sourceBranch.endsWith('master')) {
10+
$includeSuffix = $false
11+
}
1012
$bypassPackaging = $false
1113
}
1214
elseif($buildReason -eq "PullRequest")

0 commit comments

Comments
 (0)