From ff663dcab95f0ed22b7a66a02bd0a42a2bade270 Mon Sep 17 00:00:00 2001 From: martincostello Date: Wed, 29 May 2024 13:44:19 +0100 Subject: [PATCH 1/5] Fix package validation Fix the package validation job not failing if there are any issues. --- .github/workflows/build.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 556b2abe55d..fe591d7d823 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -243,6 +243,7 @@ jobs: } if ($invalidPackages -gt 0) { Write-Output "::error::$invalidPackages NuGet package(s) failed validation." + return 1 } - name: Checkout vcsjones/AuthenticodeLint From ab21009e0a6ad1474f3021af5b7a18a4f081f3c0 Mon Sep 17 00:00:00 2001 From: martincostello Date: Wed, 29 May 2024 13:56:04 +0100 Subject: [PATCH 2/5] Configure deterministic builds in project Move configuration of deterministic builds to MSBuild, rather than setting it from Cake, as this appears to have stopped working with the .NET 8.0.300 SDK. --- build.cake | 3 --- eng/Common.targets | 5 +++++ 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/build.cake b/build.cake index de523dcc8c7..be3ee387eb0 100644 --- a/build.cake +++ b/build.cake @@ -114,9 +114,6 @@ Task("__BuildSolutions") }, }; - dotNetBuildSettings.MSBuildSettings.Properties["ContinuousIntegrationBuild"] = [Environment.GetEnvironmentVariable("CI") ?? "false"]; - dotNetBuildSettings.MSBuildSettings.Properties["Deterministic"] = ["true"]; - DotNetBuild(solution.ToString(), dotNetBuildSettings); } }); diff --git a/eng/Common.targets b/eng/Common.targets index be35abaf9df..04185815e07 100644 --- a/eng/Common.targets +++ b/eng/Common.targets @@ -8,6 +8,11 @@ 0024000004800000940000000602000000240000525341310004000001000100150819e3494f97263a3abdd18e5e0c47b04e6c0ede44a6c51d50b545d403ceeb7cbb32d18dbbbcdd1d88a87d7b73206b126be134b0609c36aa3cb31dd2e47e393293102809b8d77f192f3188618a42e651c14ebf05f8f5b76aa91b431642b23497ed82b65d63791cdaa31d4282a2d6cbabc3fe0745b6b6690c417cabf6a1349c + + true + true + + From 401797402f2693341122ab8796a93b342458cc53 Mon Sep 17 00:00:00 2001 From: Martin Costello Date: Wed, 29 May 2024 14:16:35 +0100 Subject: [PATCH 3/5] Fix script Use `exit` not `return`. --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index fe591d7d823..d966fa9f633 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -243,7 +243,7 @@ jobs: } if ($invalidPackages -gt 0) { Write-Output "::error::$invalidPackages NuGet package(s) failed validation." - return 1 + exit 1 } - name: Checkout vcsjones/AuthenticodeLint From 246abaa69aec0aa8b529d7e384a62b20847b6a46 Mon Sep 17 00:00:00 2001 From: Martin Costello Date: Wed, 29 May 2024 15:23:03 +0100 Subject: [PATCH 4/5] Add missing exit Fix missing exit in other validation step. --- .github/workflows/build.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index d966fa9f633..2b52a66f119 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -154,6 +154,7 @@ jobs: } if ($invalidPackages -gt 0) { Write-Output "::error::$invalidPackages NuGet package(s) failed validation." + exit 1 } sign: From d686d602140db6b81b7d968d74827e37c1be89b1 Mon Sep 17 00:00:00 2001 From: martincostello Date: Wed, 29 May 2024 15:26:32 +0100 Subject: [PATCH 5/5] Move property declaration Try moving the property declarations into `Directory.Build.props`. --- Directory.Build.props | 4 ++++ eng/Common.targets | 5 ----- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/Directory.Build.props b/Directory.Build.props index c3398254fd3..8fa466d35af 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -2,4 +2,8 @@ true + + true + true + diff --git a/eng/Common.targets b/eng/Common.targets index 04185815e07..be35abaf9df 100644 --- a/eng/Common.targets +++ b/eng/Common.targets @@ -8,11 +8,6 @@ 0024000004800000940000000602000000240000525341310004000001000100150819e3494f97263a3abdd18e5e0c47b04e6c0ede44a6c51d50b545d403ceeb7cbb32d18dbbbcdd1d88a87d7b73206b126be134b0609c36aa3cb31dd2e47e393293102809b8d77f192f3188618a42e651c14ebf05f8f5b76aa91b431642b23497ed82b65d63791cdaa31d4282a2d6cbabc3fe0745b6b6690c417cabf6a1349c - - true - true - -