You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
C:\Windows\system32>vswhere -prerelease
Visual Studio Locator version 2.8.4+ff0de50053 [query version 3.0.4492.23473]
Copyright (C) Microsoft Corporation. All rights reserved.
C:\Windows\system32>
Hi, I have Visual Studio Build Tools 2022 17.0.5 installed on the build server, but vswhere cannot find it. Does not matter if I mention other parameters like
-products arg One or more product IDs to find. Defaults to Community, Professional, and Enterprise.
Specify "*" by itself to search all product instances installed.
See https://aka.ms/vs/workloads for a list of product IDs.
To include Build Tools you need to pass -products *. That is a duplicate of #8 and changing that would be a breaking change. For VS2017, Build Tools had no where close to the number of compilers, SDKs, tools, etc. that VS did and could not build most workloads VS could, hence not being included by default.
Thanks heaths, but id did not find it either I specify -products * or -products Microsoft.VisualStudio.Product.BuildTools or -all.
But, everthing has changed, after I installed real full-featured Visual Studio 2022 Enterprise on the build server. Suddenly vswhere can find Build Tools 2022 and also the Visual Studio 2022 Enterprise. And that means, that the Azure DevOps msbuild and vsbuild task can run successfully. But before the instalation of Visual Studio 2022 Enterprise it did not find anything and the msbuild task ended with running msbuild version 4 directly from the framework 4.0 folder which was not good. What is wierd is, that the version of vswhere did not change. All the time it is Visual Studio Locator version 2.7.1+180c706d56 [query version 3.0.4492.23473]. Maybe something has changed in the registry, who knows.
vswhere works against an API installed with Visual Studio and does not use the registry. The combination of flags matter, as a product can be in a broken, non-launchable state, prerelease, or not a default product. I encourage people to read -? to see what combination of flags to use to suit the specific needs. For example, to find any product in any state, -products * -all -prerelease would do it, but whatever you end up using may not actually launch. That's why we don't include non-launchable products by default.
Activity
heaths commentedon Jan 24, 2022
Use the
-alloption in case the instance did not complete successfully or required a reboot. Per-?usage:pavel-penka commentedon Jan 25, 2022
Hi, I have Visual Studio Build Tools 2022 17.0.5 installed on the build server, but vswhere cannot find it. Does not matter if I mention other parameters like
Visual Studio Installer can find it successfully, but it does not help me with the Azure DevOps build task.
heaths commentedon Jan 25, 2022
From the usage information, i.e.
-?:To include Build Tools you need to pass
-products *. That is a duplicate of #8 and changing that would be a breaking change. For VS2017, Build Tools had no where close to the number of compilers, SDKs, tools, etc. that VS did and could not build most workloads VS could, hence not being included by default.0x7FFFFFFFFFFFFFFF (@0x7FFFFFFFFFFFFFFF) if that resolves your problem as well, please close this issue since this is by design and described in
-?.pavel-penka commentedon Jan 25, 2022
Thanks heaths, but id did not find it either I specify
-products *or-products Microsoft.VisualStudio.Product.BuildToolsor-all.But, everthing has changed, after I installed real full-featured Visual Studio 2022 Enterprise on the build server. Suddenly vswhere can find Build Tools 2022 and also the Visual Studio 2022 Enterprise. And that means, that the Azure DevOps msbuild and vsbuild task can run successfully. But before the instalation of Visual Studio 2022 Enterprise it did not find anything and the msbuild task ended with running msbuild version 4 directly from the framework 4.0 folder which was not good. What is wierd is, that the version of vswhere did not change. All the time it is
Visual Studio Locator version 2.7.1+180c706d56 [query version 3.0.4492.23473]. Maybe something has changed in the registry, who knows.heaths commentedon Jan 25, 2022
vswhere works against an API installed with Visual Studio and does not use the registry. The combination of flags matter, as a product can be in a broken, non-launchable state, prerelease, or not a default product. I encourage people to read
-?to see what combination of flags to use to suit the specific needs. For example, to find any product in any state,-products * -all -prereleasewould do it, but whatever you end up using may not actually launch. That's why we don't include non-launchable products by default.