Contractual way to obtain location of MSBuild in SDK
See original GitHub issueToday, various things parse Base Path: (.*)
from dotnet --info
and assume they can find MSBuild there. But we have long desired to move MSBuild apart from dotnet.dll in the base path.
Perhaps we should add a separate MSBuild Base Path: (.*)
to dotnet --info
to be used if/when MSBuild is moved. We would then advise people to prefer MSBuild Base Path
over Base Path
if present.
This could also be a different invocation than dotnet --info
(say `dotnet --msbuild-path), which the client would try first. But that would have the downside of requiring two dotnet invocations instead of one when resolving MSBuild from a down-level .NET Core SDK.
Issue Analytics
- State:
- Created 5 years ago
- Reactions:1
- Comments:7 (6 by maintainers)
Top Results From Across the Web
.net - Where is MSBuild.exe installed in Windows when ...
The path to MSBuild when installed with Visual Studio is: C:\Program Files (x86)\MSBuild[version]\Bin for x86.
Read more >Demystifying the SDK Project - Dan Siegel
Even with one, it can get a little tedious to have to drill down into the Project's output folder {Path To Project}/bin/{Build Configuration} ......
Read more >Reference an MSBuild Project SDK
Learn how to use MSBuild project SDKs to simplify using software development kits that require properties and targets to be imported.
Read more >Retail software development kit (SDK) - Commerce
You can obtain new versions of the Retail SDK by applying any Commerce ... A simple MSBuild command from the root of the...
Read more >Using OpenApiReference To Generate Open API Client ...
I this post I show how you can customise the code generated by the OpenApiReference tooling from Visual Studio's Connected Services using ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
The only downside of JSON is that we’d probably want to parse it with a library, and wouldn’t want to take that dependency in MSBuildLocator.
I think for MSBuildLocator I’d prefer plain text that can be parsed simply like the initial
MSBuild Base Path:
proposal. No objection to additionally providing JSON for other use cases, though.Another option would be to have a light query syntax:
dotnet info MSBuildBasePath
anddotnet info Version
for example. That’s probably more complex than is really needed, though.