-
Notifications
You must be signed in to change notification settings - Fork 8.1k
Support creating tarball package for Linux and macOS #5085
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -38,6 +38,7 @@ dotnet-uninstall-debian-packages.sh | |
|
|
||
| # Ignore packages | ||
| *.deb | ||
| *.tar.gz | ||
| *.zip | ||
| *.rpm | ||
| *.pkg | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -11,11 +11,13 @@ param ( | |
| [ValidatePattern("^v\d+\.\d+\.\d+(-\w+\.\d+)?$")] | ||
| [ValidateNotNullOrEmpty()] | ||
| [string]$ReleaseTag, | ||
| [switch]$AppImage | ||
|
|
||
| [ValidateSet("AppImage", "tar")] | ||
| [string[]]$ExtraPackage | ||
| ) | ||
|
|
||
| $releaseTagParam = @{} | ||
| if($ReleaseTag) | ||
| if ($ReleaseTag) | ||
| { | ||
| $releaseTagParam = @{ 'ReleaseTag' = $ReleaseTag } | ||
| } | ||
|
|
@@ -25,33 +27,26 @@ try { | |
| Set-Location $location | ||
| Import-Module "$location/build.psm1" | ||
| Import-Module "$location/tools/packaging" | ||
|
|
||
| Start-PSBootstrap -Package -NoSudo | ||
| Start-PSBuild -Crossgen -PSModuleRestore @releaseTagParam | ||
|
|
||
| Start-PSPackage @releaseTagParam | ||
| if($AppImage.IsPresent) | ||
| switch ($ExtraPackage) | ||
| { | ||
| Start-PSPackage -Type AppImage @releaseTagParam | ||
| "AppImage" { Start-PSPackage -Type AppImage @releaseTagParam } | ||
| "tar" { Start-PSPackage -Type tar @releaseTagParam } | ||
| } | ||
| } | ||
| finally | ||
| { | ||
| Pop-Location | ||
| } | ||
|
|
||
| $linuxPackages = Get-ChildItem "$location/powershell*" -Include *.deb,*.rpm | ||
|
|
||
| foreach($linuxPackage in $linuxPackages) | ||
| { | ||
| Copy-Item -Path $linuxPackage.FullName -Destination $destination -force | ||
| } | ||
|
|
||
| if($AppImage.IsPresent) | ||
| $linuxPackages = Get-ChildItem "$location/powershell*" -Include *.deb,*.rpm,*.AppImage,*.tar.gz | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. In the previous commit, *.deb and .rpm packages are found under $location/powershell while *.AppImage and *.tar.gz are found under $location. With this change *.AppImage and *.tar.gz package won't be found.
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It's not under |
||
| foreach ($linuxPackage in $linuxPackages) | ||
| { | ||
| $appImages = Get-ChildItem -Path $location -Filter '*.AppImage' | ||
| foreach($appImageFile in $appImages) | ||
| { | ||
| Copy-Item -Path $appImageFile.FullName -Destination $destination -force | ||
| } | ||
| $filePath = $linuxPackage.FullName | ||
| Write-Verbose "Copying $filePath to $destination" -Verbose | ||
| Copy-Item -Path $filePath -Destination $destination -force | ||
| } | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess we can remove
-VerboseThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here I put
-Verboseexplicitly to notify that the existing package is going to be removed.