Skip to content

Get package overrides from txt file in targeting pack instead of msbuild item #2937

@nguerrera

Description

@nguerrera

dotnet/aspnetcore#7555

The file format is very similar to the item.

Before: build\netcoreapp3.0\Microsoft.AspNetCore.App.props:

<ItemGroup>
  <PackageConflictOverrides Include="Microsoft.AspNetCore.App">
      <OverriddenPackages>
        Microsoft.AspNetCore.Antiforgery|3.0.0-preview3-19111-04;
        Microsoft.AspNetCore.Authentication.Abstractions|3.0.0-preview3-19111-04;
        Microsoft.AspNetCore.Authentication.Cookies|3.0.0-preview3-19111-04;
        // ...

After: build\netcoreapp3.0\Microsoft.AspNetCore.App.PackageOverrides.txt:

Microsoft.AspNetCore.Antiforgery|3.0.0-preview3-19111-04
Microsoft.AspNetCore.Authentication.Abstractions|3.0.0-preview3-19111-04
Microsoft.AspNetCore.Authentication.Cookies|3.0.0-preview3-19111-04
// ...

The identity of the item follows from the package/file name, the metadata is the body of the txt file, where newlines delimit instead of ; with whitespace ignored.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions