سؤال

Our developers use VS 2010 to build locally; however, our CI server uses MSBuild v4.0 scripts to build code in source.

I'm aware that VS uses MSBuild behind the scenes but what are the differences between the two, if any?

هل كانت مفيدة؟

المحلول

There really aren't any differences. However, when you install VS 20xx, you get a bunch of dependencies and '.targets' installed for you.

When trying to mimic on a build machine, you may have to install some SDK's or even manually move over some .targets to get the build to work. Every blue moon, there is a .target issue that cannot be resolved on a non VS-installed build machine, which drives me nuts and makes me smirk at Microsoft.

Here are two examples from memory:

http://connect.microsoft.com/VisualStudio/feedback/details/549216/microsoft-data-schema-sqltasks-targets-file-missing-on-team-foundation-server

https://connect.microsoft.com/VisualStudio/feedback/details/580568/ability-to-build-database-projects-using-only-msbuild

Do a search in the folder:

C:\Program Files (x86)\

for

"*.targets"

and you'll get an idea of what I'm talking about (in regards to the vs installed items)

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top