问题
I'm creating some build definitions and the only difference I see between the Visual Studio Build Step and MSBuild Build Step is that the VS Build Step adds the visual studio version to the build.
Somebody can explain maybe more differences?
回答1:
They are almost the same just as Daniel mentioned. The main difference is just as what you have found: Visual Studio Build step add Visual Studio Version to the build.
Should I use the Visual Studio Build step or the MSBuild step?
If you are building a solution, in most cases you should use the Visual Studio Build step. This step automatically:
Sets the /p:VisualStudioVersion property for you. This forces MSBuild to use a particular set of targets that increase the likelihood of a successful build.
Specifies the MSBuild version argument.
In some cases you might need to use the MSBuild step. For example, you should use it if you are building code projects apart from a solution.
回答2:
Very little. The two tasks are open-source, and they both seem to do more or less the same stuff.
https://docs.microsoft.com/en-us/azure/devops/pipelines/tasks/build/msbuild?view=vsts
https://docs.microsoft.com/en-us/azure/devops/pipelines/tasks/build/visual-studio-build?view=vsts
来源:https://stackoverflow.com/questions/39667822/differences-between-visual-studio-build-step-and-msbuild-build-step