Skip to content

When using PackOnBuild in multitargeting project, only one TFM is packed #32

@kzu

Description

@kzu

Given a project:

<Project Sdk="Microsoft.NET.Sdk">
  <PropertyGroup>
    <TargetFrameworks>net472;netstandard2.0</TargetFrameworks>
  </PropertyGroup>

  <PropertyGroup>
    <PackageId>TestNuGetizer</PackageId>
    <Description>Test Package</Description>
    <PackOnBuild>True</PackOnBuild>
  </PropertyGroup>
  
  <ItemGroup>
    <PackageReference Include="NuGetizer" Version="*" />
  </ItemGroup>
</Project>

Running build will result in a package that only contains netstandard2.0 libs.

Reported by @mauroa

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions