Is there a way to let MSBuild() find the right toolversion with VS 2022 installed using legacy Cake nuget? #3785
-
I am using using the legacy Cake-Nuget and restore it on build, then run Cake.exe Since I dont want to rewrite my whole build script I would like to know, if there is any way to get MSBuild() with 2022 working. I am on Cake 1.3.0 right now. Thanks! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
@janniksam Upgrading from Cake v1.3 to Cake v2.0 (and use .NET Tool) is probably easier than you think it is, and likely not a rewrite. Check out the steps laid out by @nils-a here: #3744 (comment) But to answer your question, an easy way to use MSBuild / VS2022 in older versions of Cake is by using |
Beta Was this translation helpful? Give feedback.
@janniksam Upgrading from Cake v1.3 to Cake v2.0 (and use .NET Tool) is probably easier than you think it is, and likely not a rewrite. Check out the steps laid out by @nils-a here: #3744 (comment)
But to answer your question, an easy way to use MSBuild / VS2022 in older versions of Cake is by using
vswhere
to locate where MSBuild is installed. There's an example by @DrewRhoades here: #3671 (comment)