mirror of
https://github.com/PowerShell/PowerShell.git
synced 2024-11-24 10:23:26 +08:00
Be smarter about nuget package names on appveyor
This commit is contained in:
parent
b654b7d4b1
commit
04c8cdbb20
13
appveyor.yml
13
appveyor.yml
@ -93,7 +93,18 @@ on_finish:
|
||||
$artifacts.Add($zipFilePath)
|
||||
$artifacts.Add($zipFileFullPath)
|
||||
|
||||
Publish-NuGetFeed -OutputPath .\nuget-artifacts -VersionSuffix "b$($env:APPVEYOR_BUILD_NUMBER)"
|
||||
if ($env:APPVEYOR_REPO_TAG_NAME)
|
||||
{
|
||||
# ignore the first part of semver, use the preview part
|
||||
$preReleaseVersion = ($env:APPVEYOR_REPO_TAG_NAME).Split('-')[1]
|
||||
}
|
||||
else
|
||||
{
|
||||
$previewLabel = (git describe --abbrev=0).Split('-')[1]
|
||||
$preReleaseVersion = "$previewLabel.$($env:APPVEYOR_BUILD_NUMBER)"
|
||||
}
|
||||
|
||||
Publish-NuGetFeed -OutputPath .\nuget-artifacts -VersionSuffix $preReleaseVersion
|
||||
|
||||
$artifacts += (ls .\nuget-artifacts | % {$_.FullName})
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user