summaryrefslogtreecommitdiffhomepage
path: root/build.ps1
diff options
context:
space:
mode:
Diffstat (limited to 'build.ps1')
-rw-r--r--build.ps18
1 files changed, 6 insertions, 2 deletions
diff --git a/build.ps1 b/build.ps1
index a3156d0..25f2953 100644
--- a/build.ps1
+++ b/build.ps1
@@ -113,7 +113,9 @@ function New-ReleaseZip {
# Create distribution directories
if (-not (Test-Path $DistDir)) {
New-Item -ItemType Directory -Path $DistDir | Out-Null
- } else {
+ }
+
+ if (Test-Path $DistPath) {
Remove-Item -Recurse -Force -Path $DistPath
}
New-Item -ItemType Directory -Path $DistPath | Out-Null
@@ -144,7 +146,9 @@ function New-ReleaseZip {
# 4. Compress files into a ZIP archive
Write-Host "Compressing files into '$ZipBallPath'..."
- Compress-Archive -Path (Join-Path $DistPath "*") -DestinationPath $ZipBallPath -Force
+ Push-Location -Path $DistDir
+ Compress-Archive -Path $DistName -DestinationPath $ZipBallPath -Force
+ Pop-Location
# 5. Generate SHA256 checksum
Write-Host "Generating SHA256 checksum..."