dotnet / dotnet/msbuild

Paths starting with `./` in DefaultItemExcludes are not properly handled

Open
#5,281 4 comments 1 reaction 0 assignees View on GitHub
bug triaged
Dominant language
C#
Stars
5.5k
Forks
1.5k
Avg merge
1d 13h
Merged PRs (30d)
133

Description

This is probably a flaw in the implementation of [FileMatcher](/microsoft/msbuild/blob/vs16.5/src/Shared/FileMatcher.cs).

### Steps to reproduce

See [here](https://github.com/lanfeust69/TestDefaultItemExcludes)

```
msbuild /bl /p:WithDot=True
```
### Expected behavior

`None` items should only contain the `.git*` files and `ReadMe.md`

### Actual behavior

`None` items also include the `bin` and `Data` contents.

### Environment data
`msbuild /version` output:
`16.5.0.12403`

OS info:
both Windows 10 and Ubuntu 19.10

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with src/Shared/FileMatcher.cs and reproduce the issue using the linked example with `msbuild /bl /p:WithDot=True`. Compare the `None` items produced for paths beginning with `./` against the expected `.git*` files and `ReadMe.md`; done means `bin` and `Data` contents are excluded on both reported environments.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
build-system
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.