Skip to content

Commit 943f79b

Browse files
committed
Replace 7zip with Compress-Archive
1 parent 8275f3a commit 943f79b

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

extension/BuildPhpExtension/private/Add-Package.ps1

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -108,13 +108,15 @@ function Add-Package {
108108
Add-Content "artifact=$artifact.zip" -Path $env:GITHUB_OUTPUT -Encoding utf8
109109
}
110110

111-
7z a -sdel "$artifact.zip" *
111+
Compress-Archive -Path * -DestinationPath "$artifact.zip"
112+
Remove-Item * -Recurse -Force -Exclude *.zip
112113

113114
Set-Location $currentDirectory
114115
New-Item -Path $currentDirectory\artifacts\logs -ItemType Directory -Force | Out-Null
115116
Copy-Item -Path build-*.txt -Destination artifacts\logs\ -Force
116117
Set-Location $currentDirectory\artifacts\logs
117-
7z a -sdel "$artifact.zip" *
118+
Compress-Archive -Path * -DestinationPath "$artifact.zip"
119+
Remove-Item * -Recurse -Force -Exclude *.zip
118120
Set-GAGroup end
119121
Add-BuildLog tick "Packaging" "Extension $($Config.name) packaged successfully"
120122
} catch {

0 commit comments

Comments
 (0)