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

Attempt to fix the extension not finding Mono #5484

Merged
merged 2 commits into from
Dec 11, 2022
Merged

Conversation

ArtyIF
Copy link
Contributor

@ArtyIF ArtyIF commented Dec 5, 2022

Should fix #5454

@ArtyIF
Copy link
Contributor Author

ArtyIF commented Dec 5, 2022

@microsoft-github-policy-service agree

Copy link
Contributor

@filipw filipw left a comment

Choose a reason for hiding this comment

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

Thanks this seems good to me.
The older MSBuilds only support single dash args like -version. The newer ones (16.10+) support both --version and -version so of course it makes sense to use the ones that have wider compatibility.

Tagging @333fred @JoeRobich @dibarbet

Copy link
Member

@dibarbet dibarbet left a comment

Choose a reason for hiding this comment

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

Makes sense to me. I'll make sure this in the next release.

@RaulPROP
Copy link

RaulPROP commented Dec 8, 2022

On Ubuntu (22.04 at least), there is also another problem: the msbuild command is a subcommand of dotnet. So to get the version the correct command should be dotnet msbuild -version -nologo.

@333fred
Copy link
Member

333fred commented Dec 8, 2022

@RaulPROP mono msbuild is not a subcommand of dotnet, which is what this is looking for.

@ArtyIF
Copy link
Contributor Author

ArtyIF commented Dec 9, 2022

On Ubuntu (22.04 at least), there is also another problem: the msbuild command is a subcommand of dotnet. So to get the version the correct command should be dotnet msbuild -version -nologo.

This function is only called with useModernNet set to false, i.e. when using Mono instead of .NET 5+ SDK.

@333fred 333fred enabled auto-merge (squash) December 11, 2022 17:43
@333fred 333fred merged commit 2c61b60 into dotnet:master Dec 11, 2022
@ArtyIF ArtyIF deleted the patch-1 branch December 15, 2022 19:27
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.

1.25.2 no longer finds Mono installation
5 participants