Open sayedihashimi opened 1 month ago
By adding
.generated
to the sln name the csproj and sln file no longer match on file name, so when users run commands likedotnet build
they will get a prompt asking them to select the sln or project file to build.
@baronfel found the MSBuild-side code that does this: https://github.com/dotnet/msbuild/blob/b381fcd79588b14ab2b6ab09cb57035d0336852f/src/MSBuild/XMake.cs#L3554-L3563
We could certainly expand the pattern there but I would not expect that to be approved for servicing for older .NET SDKs, so it'd be .NET 9+.
This seems to lead to issues when trying to debug newly created Azure Function apps through the VS code extension.
Describe the Issue
In the latest preview of C# Dev Kit when you open a folder that contains a csproj but no sln it will create a sln file named
{foldername}.generated.sln
and previously it would create{foldername}.sln
.Let's say there is a folder named
MyApp
, the folder would typically containMyApp.csproj
and in the past when using C# Dev Kit it would createMyApp.sln
. In this cases since the names of the sln and csproj match when you run dotnet commands likedotnet build
,dotnet clean
, etc they would automatically pickup the sln file and use that.By adding
.generated
to the sln name the csproj and sln file no longer match on file name, so when users run commands likedotnet build
they will get a prompt asking them to select the sln or project file to build.This change should be reverted, and we should go back to the previous behavior.
cc @richlander @rainersigwald
Steps To Reproduce
No response
Expected Behavior
No response
Environment Information
No response