microsoft / vswhere

Locate Visual Studio 2017 and newer installations
MIT License
921 stars 97 forks source link

-version does not allow for a single version value #270

Closed tydunkel closed 1 year ago

tydunkel commented 2 years ago

Running vswhere.exe -version 17 doesn't set the version range to be [17,18) but rather uses the max version for the upper bound. It may be less confusing to support a single version value for -version and set the maximum of the range to be the same as the minimum.

heaths commented 2 years ago

This is the documented behavior and consistent with VSIXInstaller version ranges. A single version means [17,). Not to mention, changing this would be a breaking change for anyone looking for, say, 15+ via -version 15.

heaths commented 2 years ago

If anything, perhaps we can expand on the version syntax or at least link to https://github.com/microsoft/vswhere/wiki/Examples (maybe add a heading directly for version syntax, or add a new page and link to that from examples).