From 4b97085d7ae6c4a14425fd2378618ee58bbaa8c4 Mon Sep 17 00:00:00 2001 From: Jo Shields Date: Fri, 7 Jun 2024 11:06:49 -0400 Subject: [PATCH] Add a stub packageSourceMapping Without packageSourceMapping, you may receive NuGet warning NU1507. Building with WarnAsError will elevate this to a fatal error. ``` C:\d\source-indexer\bin\repo\machinelearning\test\Microsoft.ML.CpuMath.UnitTests\Microsoft.ML.CpuMath.UnitTests.csproj : error NU1507: Warning As Error: There are 9 package sources defined in your configuration. When using central package management, please map your package sources with package source mapping (https://aka.ms/nuget-package-source-mapping) or specify a single package source. The following sources are defined: dotnet-public, dotnet-tools, dotnet-libraries, dotnet-eng, vs-buildservices, dotnet5-roslyn, mlnet-daily, mlnet-assets, dotnet8 [C:\d\source-indexer\bin\repo\machinelearning\Microsoft.ML.sln] ``` Using * as a pattern means any repo can supply any package, the pattern can be further refined later. --- NuGet.config | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/NuGet.config b/NuGet.config index cf1fc2312f..15f4fc551b 100644 --- a/NuGet.config +++ b/NuGet.config @@ -15,6 +15,35 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +