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

Gradle issue when setting build tools #86

Open
Karlovsky120 opened this issue Nov 15, 2023 · 6 comments
Open

Gradle issue when setting build tools #86

Karlovsky120 opened this issue Nov 15, 2023 · 6 comments

Comments

@Karlovsky120
Copy link

Karlovsky120 commented Nov 15, 2023

I have two "versions" of visual studio: Build tools and Team explorer.

Build tools is essentially MSBuild, while Team explorer is CLI and GUI client for TFVC.
Version of Team explorer that I have is newer than that of Build tools.

This means that the this bit here:

exec {
    executable "${rootDir}\\tools\\vswhere.exe"
    args '-latest','-property','installationPath','-products','*'
    standardOutput = stdout
    workingDir rootDir
}

returns the location of Team explorer instead of Build tools.

I've fixed the issue for my case by replacing the '*' after the products with 'Build Tools', but that won't work for most people, since I belive most people have msbuild.exe as a part of proper visual studio installation.

@matkoch
Copy link
Member

matkoch commented Nov 16, 2023

Could you please check if vswhere -latest -requires Microsoft.Component.MSBuild -find MSBuild\**\Bin\MSBuild.exe returns the correct path for you?

@Karlovsky120
Copy link
Author

It returns Error 0x57: Unknown parameter: find.
If I remove find and the path after it, it just returns nothing.

@matkoch
Copy link
Member

matkoch commented Nov 16, 2023

Sorry, you need to download the latest vswhwere executable.

https://github.com/microsoft/vswhere/releases/tag/3.1.7

@Karlovsky120
Copy link
Author

Why isn't the newest version in this repository?

Either way, I've downloaded the linked version and ran it with the provided arguments. It doesn't return an error, but it doesn't return anything else either.

I've tried running it as is and as an administrator with the same results.

@matkoch
Copy link
Member

matkoch commented Nov 16, 2023

Why isn't the newest version in this repository?

Because there's no reason to.

Thanks for checking the command.

@Karlovsky120
Copy link
Author

Because there's no reason to.

Fair enough.

Feel free to notify me if I can help any other way!

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

No branches or pull requests

2 participants