Skip to content

Commit 3b684c6

Browse files
authored
Fix DefaultExcludesInProjectFolder value ignored (#24063)
* Fix DefaultExcludesInProjectFolder value ignored The DefaultItemExcludesInProjectFolder property is never defined and was likely forgotten to be renamed. Because of that, the DefaultExcludesInProjectFolder property overwrites any user set value. Add DefaultExcludesInProjectFolder and keep DefaultItemExcludesInProjectFolder to not break existing consumers.
1 parent 48db4ad commit 3b684c6

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/Tasks/Microsoft.NET.Build.Tasks/targets/Microsoft.NET.Sdk.DefaultItems.targets

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,9 @@ Copyright (c) .NET Foundation. All rights reserved.
3636

3737
<!-- WARNING: This pattern is there to ignore folders such as .git and .vs, but it will also match items included with a
3838
relative path outside the project folder (for example "..\Shared\Shared.cs"). So be sure only to apply it to items
39-
that are in the project folder. -->
40-
<DefaultExcludesInProjectFolder>$(DefaultItemExcludesInProjectFolder);**/.*/**</DefaultExcludesInProjectFolder>
41-
39+
that are in the project folder. Support both DefaultItemExcludesInProjectFolder and DefaultExcludesInProjectFolder
40+
properties because of a naming mistake. -->
41+
<DefaultExcludesInProjectFolder>$(DefaultExcludesInProjectFolder);$(DefaultItemExcludesInProjectFolder);**/.*/**</DefaultExcludesInProjectFolder>
4242
</PropertyGroup>
4343

4444
<!-- Set the default versions of the NETStandard.Library or Microsoft.NETCore.App packages to reference.

0 commit comments

Comments
 (0)