f7009106d8
This commit implements solution configuration to project configuration mapping. Previously, when a project was added to the solution with the `sln add` command, solution configurations would be mapped to a project configuration and platform of the same name, regardless of whether or not the project had a configuration or platform of that name. This caused the solution to appear dirty when opened in Visual Studio if the configuration or platform did not exist at the project level because Visual Studio would attempt to correct the mapping. The fix is to check what configurations and platforms are supported by the project and only map to what is present. If a solution configuration can't be mapped, the first configuration/platform supported by the project is chosen; this is consistent with how Visual Studio does the fallback mapping. Fixes #6221.
15 lines
372 B
C#
15 lines
372 B
C#
// Copyright (c) .NET Foundation and contributors. All rights reserved.
|
|
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
|
|
|
|
using System;
|
|
|
|
namespace ProjectWithMatchingConfigs
|
|
{
|
|
public static class Library
|
|
{
|
|
public static string GetMessage()
|
|
{
|
|
return "Hello World!";
|
|
}
|
|
}
|
|
}
|