-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Closed
Labels
Area: LanguageIssues impacting the MSBuild programming language.Issues impacting the MSBuild programming language.help wantedIssues that the core team doesn't plan to work on, but would accept a PR for. Comment to claim.Issues that the core team doesn't plan to work on, but would accept a PR for. Comment to claim.triaged
Milestone
Description
Steps to reproduce
I am trying to set copy local false in all my projects (outputtype=library)from the Driectory.build.props file in the root folder.
<When Condition=" '$(OutputType)'=='Library' ">
<ItemDefinitionGroup>
<Reference>
<Private>False</Private>
</Reference>
<ProjectReference>
<Private>False</Private>
</ProjectReference>
</ItemDefinitionGroup>
</When>
<When Condition=" '$(OutputType)'=='exe' ">
<ItemDefinitionGroup>
<Reference>
<Private>True</Private>
</Reference>
<ProjectReference>
<Private>True</Private>
</ProjectReference>
</ItemDefinitionGroup>
</When>
should I be able to use conditional constructs this way?
I tried above but get an error
The element <ItemDefinitionGroup> beneath element <When> is unrecognized.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
Area: LanguageIssues impacting the MSBuild programming language.Issues impacting the MSBuild programming language.help wantedIssues that the core team doesn't plan to work on, but would accept a PR for. Comment to claim.Issues that the core team doesn't plan to work on, but would accept a PR for. Comment to claim.triaged