From 952cf90e4433d02b571d1b1c0d118d9c432e0158 Mon Sep 17 00:00:00 2001 From: Albert Cheng Date: Tue, 24 Aug 2021 11:50:36 -0700 Subject: [PATCH] Fix --- .../templates/stages/archetype-net-release.yml | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/eng/pipelines/templates/stages/archetype-net-release.yml b/eng/pipelines/templates/stages/archetype-net-release.yml index 96c7911036d07..679e5f44474d7 100644 --- a/eng/pipelines/templates/stages/archetype-net-release.yml +++ b/eng/pipelines/templates/stages/archetype-net-release.yml @@ -53,11 +53,13 @@ stages: mkdir InstallationCheck - pwsh: | Write-Host "Create new console" - dotnet new console -n "Installation.Check" + dotnet new console + mkdir packages + Write-Host "Installing .nupkg into package source" + $nupkg = Get-ChildItem -Path "$(Pipeline.Workspace)/${{parameters.ArtifactName}}/${{artifact.name}}/*.nupkg" -Exclude "*.symbols.nupkg" + nuget add "$($nupkg)" -Source ./packages Write-Host "Adding package dependency for ${{artifact.name}}" - dir - tree /F - dotnet add "Installation.Check" package ${{artifact.name}} + dotnet add package ${{artifact.name}} -s ./packages Write-Host "NuGet Cache list:" nuget locals all -list Write-Host "Clearing NuGet package cache"