by pauljz on 3/18/15, 8:08 PM with 173 comments
by jammycakes on 3/19/15, 6:47 AM
MSBuild was originally designed as a file format for Visual Studio solution and project files, generally intended to be managed by a GUI. If all you are interested in is spitting out binaries, it works pretty well, and the fact that it adds a ton of extensibility is actually quite useful.
It becomes problematic though when people try to use it to manage their entire end-to-end build process -- running tests, generating reports, stopping and starting servers, manipulating configuration files and so on. When you get to that level you really need a proper scripting language with a clean, readable way of expressing loops, conditions and subroutines, and that's where MSBuild falls down -- XML is horrible for that kind of thing, and the declarative, task-based paradigm simply isn't flexible enough.
Unfortunately, because of the all too common insistence of many .NET teams on being spoon-fed by Microsoft, a lot of projects stick with MSBuild for their entire end-to-end build process regardless, simply because they believe That Is How Microsoft Wants You To Do It.
by MrZipf on 3/19/15, 7:52 AM
MSBuild is essentially a clone ant, and it's not a bad tool per se. For the devdiv engineering team it allowed them to get off the horrible pre-msbuild project files.
The messiness came with solution files (since VS uses solution files and project files). Unfortunately, they left the also awful solution files around. And this added an alternate way to specify dependencies between projects. VS solution files are awful to maintain - just a bag of guids that makes resolving conflicts very hard for humans and VS is poor at automatically resolving them (very noticeable when you get >3 developers on a project).
The solution to the messiness would be to use an MSBuild project file instead of a solution file. It'd have to conform to a schema VS understands, but it's not rocket science. However, fixing this would require the VS source code and MSFT to accept a patch.
Using Visual Studio, gui or command line, uses the MSBuild engine though the VS wrapping does some internal caching that occasionally makes it wrong (ah! There's a cryptic flag that fixes this).
by rsuelzer on 3/19/15, 3:25 AM
by zaphar on 3/18/15, 9:22 PM
However the mono xbuild tool has subtle incompatibilities and holes in functionality as compared to msbuild so for no other reason than having the "same" build tool in mono and .Net I applaud this move.
by serve_yay on 3/18/15, 8:56 PM
by mattchamb on 3/18/15, 9:22 PM
http://stackoverflow.com/questions/707107/library-for-parsin...
by akandiah on 3/19/15, 5:44 AM
by arrowgunz on 3/18/15, 10:10 PM
by dclusin on 3/18/15, 8:39 PM
by pionar on 3/18/15, 9:03 PM
by ghuntley on 3/19/15, 7:03 AM
by acqq on 3/18/15, 9:43 PM
by O____________O on 3/18/15, 9:44 PM
Honestly, I don't know why anyone wants MSBuild. Poking around, people cite not needing to install the VS IDE on build servers, but I see zero drawback to doing that. Why would I want to maintain project dependencies, build orders, and whatnot in two places, when I could just build in exactly the same way, using the same solution/project files, on my dev box and my build server?
It seems to me that this is actually vastly more meaningful to traditionally open-source LAMP developers who are considering C# and ASP.Net on Linux in the future.
by pvsnp on 3/18/15, 8:32 PM
by michaelfeathers on 3/19/15, 2:16 AM
by angersock on 3/18/15, 9:13 PM
:)
by voltagex_ on 3/18/15, 11:21 PM
by julbaxter on 3/18/15, 9:26 PM
by detay on 3/19/15, 11:42 AM
by edandersen on 3/18/15, 8:54 PM
by steveklabnik on 3/18/15, 9:02 PM
by nickbauman on 3/19/15, 12:24 AM
by edandersen on 3/18/15, 9:25 PM
3 commits. Because MSBuild just happened.
The whole point of open source is that you get to go back and see how the software evolved. Git blame. Everybody learns.