Skip to content
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

Respect response files (ignoreProjectExtensions) property #9677

Merged

Conversation

f-alizada
Copy link
Contributor

Fixes #9507

Context

The ignoreProjectExtensions are not respected if specidified in response file on project level.
The exception will be thrown in case there are ambiguous files identified in provided directory. Example:
Directiory contains:

1.sln 
2.csproj 

The build fails since there are multiple files identified to build.
IgnoreProjectExtensions: .sln solves the situation but when specified in response file on project level the error will raise before the usage of the response file.

Changes Made

Identifying projectFile was extracted from CheckAndGatherProjectAutoResponseFile, and moved to ProcessCommandLineSwitches.

Testing

Added specific to the case test case
All existing tests should pass

Copy link
Member

@JanKrivanek JanKrivanek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good - just some minor comments

src/MSBuild.UnitTests/XMake_Tests.cs Outdated Show resolved Hide resolved
src/MSBuild/XMake.cs Outdated Show resolved Hide resolved
Copy link
Member

@JanKrivanek JanKrivanek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! Thanks for addressign comments!

src/MSBuild.UnitTests/XMake_Tests.cs Outdated Show resolved Hide resolved
src/MSBuild/XMake.cs Show resolved Hide resolved
src/MSBuild/XMake.cs Outdated Show resolved Hide resolved
src/MSBuild/XMake.cs Show resolved Hide resolved
@f-alizada f-alizada merged commit 668b199 into dotnet:main Feb 6, 2024
8 checks passed
@f-alizada f-alizada deleted the dev/f-alizada/respect-response-file branch June 14, 2024 10:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug]: ignoreProjectExtensions flag doesn't work when specified from an RSP file
3 participants