Skip to content

Prepare for a 'netcoreapp3.1' TFM #13581

Closed
@dougbu

Description

@dougbu

To minimize merge conflicts from 'release/3.1' -> 'master':

  1. Remove most .NET Core TFMs from our project files and replace “netcoreapp3.0” with a property defined in the root-level Directory.Build.props file. This is a purely mechanical change (especially in VS Code) but will touch hundreds of files. (There are 631 .csproj files in the AspNetCore repo.)
    • property should be named $(DefaultNetCoreTargetFramework) to match 'master'
  2. Change our ref/ assembly generation to name the C# files *.netcoreapp.cs instead of *.netcoreapp3.0.cs. The work is mechanical but involves a couple of quick steps after updating a few lines in the MSBuild code we use to generate the ref assemblies. (There are 110 *.netcoreapp3.0.cs files in the AspNetCore repo. The .csproj files in the same directories will also be updated.)
    • update eng\scripts\GenerateReferenceAssemblies.ps1 to match 'master'
    • git rm **/*.netcoreapp3.0.cs
    • execute eng\scripts\GenerateReferenceAssemblies.ps1
  3. Change our #if NETCOREAPP3_0 checks to be #if NETCOREAPP. (There are 12 *.cs files in the AspNetCore repo using the 3.0 symbol.)
  4. Change version prefix from alpha to preview.

Details

These changes have the added benefit of easing TFM changes e.g. adjusting to the new netcoreapp3.1 TFM but that is not the primary goal. W.r.t. merge conflicts:

  1. Avoids merge conflicts as we touch nearby lines in the project files.
  2. Avoids merge conflicts as ref assemblies need to be updated. Without the proposed change, the generated files won’t exist in the target repo and the files that do exist will need to be manually updated. This may be change with the largest impact.
  3. Avoids merge conflicts as we touch nearby lines in the C# files.

Metadata

Metadata

Assignees

Labels

area-infrastructureIncludes: MSBuild projects/targets, build scripts, CI, Installers and shared framework

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions