mirror of
https://github.com/PowerShell/PowerShell
synced 2026-06-08 12:12:50 +00:00
Remove references to uninitialized variable (#8849)
Remove references to uninitialized variable regressed in #8822 ## PR Context Some artifacts never got published because the conditions would never be true
This commit is contained in:
+6
-6
@@ -512,10 +512,10 @@ function Invoke-AppveyorFinish
|
||||
$artifacts = New-Object System.Collections.ArrayList
|
||||
foreach ($package in $packages) {
|
||||
if (Test-Path $package)
|
||||
{
|
||||
Write-Log "Package found: $package"
|
||||
{
|
||||
Write-Log "Package found: $package"
|
||||
}
|
||||
else
|
||||
else
|
||||
{
|
||||
Write-Warning -Message "Package NOT found: $package"
|
||||
}
|
||||
@@ -764,13 +764,13 @@ function Invoke-LinuxTests
|
||||
# 1 - It's a Daily build (already checked, for not a PR)
|
||||
# 2 - We have the info to publish (NUGET_KEY and NUGET_URL)
|
||||
# 3 - it's a nupkg file
|
||||
if($isDailyBuild -and $NugetKey -and $env:NUGET_URL -and [system.io.path]::GetExtension($package) -ieq '.nupkg')
|
||||
if($isFullBuild -and $NugetKey -and $env:NUGET_URL -and [system.io.path]::GetExtension($package) -ieq '.nupkg')
|
||||
{
|
||||
Write-Log "pushing $package to $env:NUGET_URL"
|
||||
Start-NativeExecution -sb {dotnet nuget push $package --api-key $NugetKey --source "$env:NUGET_URL/api/v2/package"} -IgnoreExitcode
|
||||
}
|
||||
|
||||
if($isDailyBuild)
|
||||
if($isFullBuild)
|
||||
{
|
||||
if ($package -isnot [System.IO.FileInfo])
|
||||
{
|
||||
@@ -795,7 +795,7 @@ function Invoke-LinuxTests
|
||||
Copy-Item $armPackage -Destination "${env:BUILD_ARTIFACTSTAGINGDIRECTORY}" -Force
|
||||
}
|
||||
|
||||
if ($isDailyBuild)
|
||||
if ($isFullBuild)
|
||||
{
|
||||
New-TestPackage -Destination "${env:SYSTEM_ARTIFACTSDIRECTORY}"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user