From a12afd3c9e734cc0d4c97d8383d9aecdcee5e103 Mon Sep 17 00:00:00 2001 From: Nicholas Blumhardt Date: Wed, 22 Jun 2022 09:28:37 +1000 Subject: [PATCH] Fix version suffixing in build script --- Build.ps1 | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/Build.ps1 b/Build.ps1 index c61d48d..03096ae 100644 --- a/Build.ps1 +++ b/Build.ps1 @@ -23,15 +23,12 @@ echo "build: Version suffix is $suffix" & dotnet test -c Release "./test/$projectName.Tests/$projectName.Tests.csproj" if ($LASTEXITCODE -ne 0) { throw "dotnet test failed" } -$src = "./src/$projectName" - -& dotnet build -c Release --version-suffix=$suffix "$src/$projectName.csproj" -if ($LASTEXITCODE -ne 0) { throw "dotnet build failed" } +$csproj = "./src/$projectName/$projectName.csproj" if ($suffix) { - & dotnet pack -c Release -o ./artifacts --no-build --version-suffix=$suffix "$src/$projectName.csproj" + & dotnet pack "$csproj" -c Release -o ./artifacts --version-suffix=$suffix } else { - & dotnet pack -c Release -o ./artifacts --no-build "$src/$projectName.csproj" + & dotnet pack "$csproj" -c Release -o ./artifacts } if ($LASTEXITCODE -ne 0) { throw "dotnet pack failed" }