New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix ignored paths used by binary tool #40777
Conversation
src/SourceBuild/content/eng/tools/BinaryToolKit/DetectBinaries.cs
Outdated
Show resolved
Hide resolved
src/SourceBuild/content/eng/tools/BinaryToolKit/DetectBinaries.cs
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why are we ignoring certain binaries anyway? If we're not going to honor the .gitignore files of the repos, then what service are we providing to the developer anyway by keeping some binaries in the repo but not others?
My only thought is that we can't rely on the .gitignore files, but we should still ignore certain paths like the git files, artifacts, and downloaded PSB packages. If someone wants to run just the validation for example, it would be unfortunate if the tool removed their build artifacts. |
Per an offline discussion w/@ella, we concluded the following:
|
Closes dotnet/source-build#4391
The binary tool was not detecting binaries in repos where a .git repo was not present, because all files were being ignored upon initialization of said git repo.
Furthermore, some repos have been including binaries in their .gitignore files. This results in those binaries going undetected by the tool. See https://github.com/dotnet/dotnet/blob/8f3d7c26c231d54ad230f427a1005278c815dde6/src/fsharp/.gitignore#L43 as an example.
This PR changes the ignored paths from relying on the .gitignore files to simply hardcoding paths to ignore.