MSBuild: Difference between revisions
Undid revision 829924946 by Special:Contributions/2600:1003:B841:56EC:E4AF:2E3D:7C2:301B name calling is not useful but then again it is just as useless to request citational burden of proof to specify an apple is not an orange unless there is some significant public confusion on the topic |
15.6.82 |
||
Line 9: | Line 9: | ||
| logo = <!-- Image name is enough --> |
| logo = <!-- Image name is enough --> |
||
| developer = [[Microsoft]] |
| developer = [[Microsoft]] |
||
| released = |
| released = {{Start date and age|2003|df=dmy}} |
||
| discontinued = |
| discontinued = |
||
| latest release version = 15. |
| latest release version = 15.6.82 |
||
| latest release date = {{Start date and age| |
| latest release date = {{Start date and age|2018|03|13|df=dmy}}<ref>{{cite web |title=Releases · Microsoft/msbuild |url=https://github.com/Microsoft/msbuild/releases |website=[[GitHub]] |publisher=[[Microsoft]] |accessdate=2018-02-16}}</ref> |
||
| status = |
| status = |
||
| programming language = [[C Sharp (programming language)|C#]] |
| programming language = [[C Sharp (programming language)|C#]] |
||
Line 32: | Line 32: | ||
MSBuild can build a project against a supported .NET Framework version of choice. This feature is called "multitargeting". Any given build of a project, however, can only target one version of the framework at a time.<ref>{{cite web|title=MSBuild Multitargeting Overview|url=https://msdn.microsoft.com/en-us/library/hh264223.aspx|work=[[MSDN]]|publisher=[[Microsoft]]|accessdate=11 December 2013}}</ref> |
MSBuild can build a project against a supported .NET Framework version of choice. This feature is called "multitargeting". Any given build of a project, however, can only target one version of the framework at a time.<ref>{{cite web|title=MSBuild Multitargeting Overview|url=https://msdn.microsoft.com/en-us/library/hh264223.aspx|work=[[MSDN]]|publisher=[[Microsoft]]|accessdate=11 December 2013}}</ref> |
||
==History== |
|||
MSBuild was first created in 2003 targeting [[.NET Framework 2.0]] for use in [[Visual Studio 2005]] (codenamed Whidbey)<ref>{{cite web |title=Building, Testing, and Deployment |department=What's New in Visual Studio 2005 |website=MSDN |publisher=Microsoft |url=http://msdn.microsoft.com/en-us/library/88fx1xy0(VS.80).aspx#rtmbuildtestdeploy |archiveurl=https://web.archive.org/web/20140826051347/http://msdn.microsoft.com/en-us/library/88fx1xy0(VS.80).aspx#rtmbuildtestdeploy |archivedate=2014-08-26}}</ref> and [[Windows Vista]] (codenamed Longhorn).<ref name="Sneath2004">{{cite web |last1=Sneath |first1=Tim |date=2004-07-19 |title=MSBuild: The New Build System for Visual Studio 2005 and Longhorn |department=Tim Sneath |website=MSDN Blogs |url=https://blogs.msdn.microsoft.com/tims/2004/07/19/msbuild-the-new-build-system-for-visual-studio-2005-and-longhorn/ |df=mdy |accessdate=2018-04-22}}</ref><ref name="England2010">{{cite web |last1=England |first1=Chuck |date=2010-02-25 |title=Getting Started with MSBuild |department=The Visual Studio Blog |website=MSDN Blogs |url=https://blogs.msdn.microsoft.com/visualstudio/2010/02/25/getting-started-with-msbuild/ |df=mdy |accessdate=2018-04-22}}</ref> |
|||
==Terminology== |
==Terminology== |
Revision as of 03:02, 23 April 2018
This article has multiple issues. Please help improve it or discuss these issues on the talk page. (Learn how and when to remove these messages)
|
Developer(s) | Microsoft |
---|---|
Initial release | 2003 |
Stable release | 15.6.82
/ 13 March 2018[1] |
Repository | |
Written in | C# |
Platform | .NET Framework |
Type | Build tool |
License | MIT License |
Website | docs |
Microsoft Build Engine, better known as MSBuild,[2][3] is a free and open-source build tool set for managed code as well as native C++ code and was part of .NET Framework. Visual Studio depends on MSBuild, but MSBuild does not depend on Visual Studio.[4] Visual Studio Application Lifecycle Management depends on MSBuild to perform team builds via the Team Foundation Server.[4]
Overview
MSBuild is a build tool that helps automate the process of creating a software product, including compiling the source code, packaging, testing, deployment and creating documentations. With MSBuild, it is possible to build Visual Studio projects and solutions without the Visual Studio IDE installed. MSBuild is free and open-source.[5] MSBuild was previously bundled with .NET Framework; starting with Visual Studio 2013, however, it is bundled with Visual Studio instead.[6] MSBuild is a functional replacement for the nmake utility, which remains in use in projects that originated in older Visual Studio releases.
MSBuild acts on MSBuild project files which have a similar XML syntax to Apache Ant or NAnt. Even though the syntax is based upon well-defined XML schema, the fundamental structure and operation is comparable to the traditional Unix make utility: the user specifies what will be used (typically source code files) and what the result should be (typically a static library, DLL or an executable application), but the utility itself decides what to do and the order in which to carry out the build.
MSBuild can build a project against a supported .NET Framework version of choice. This feature is called "multitargeting". Any given build of a project, however, can only target one version of the framework at a time.[7]
History
MSBuild was first created in 2003 targeting .NET Framework 2.0 for use in Visual Studio 2005 (codenamed Whidbey)[8] and Windows Vista (codenamed Longhorn).[9][10]
Terminology
This section may be confusing or unclear to readers. In particular, it is unclear what this section is talking about and what is the nature of, say, a "Target" or "Task". Examples would help. (April 2013) |
- Target
- A Target contains a set of tasks for MSBuild to execute. The focus of MSBuild is the result Target specified when invoking MSBuild with the project file. This is because a Project may contain several Target entries, each executed sequentially (and conditionally). Subsequent dependent Targets are executed before the requested Target. The execution flow of the current Target can be directed using the following attributes: Condition, BeforeTargets, AfterTargets, & DependsOnTargets. Each Target may be self-contained with the necessary Tasks to complete itself. A Target is typically an action executed on a file, set of files or directory.
- Task
- A Task is a command which is executed in order to complete a Target. Tasks are used to group and execute any number of actions during the build process. They are typically implemented in a .NET assembly as a class which inherits from the Task class or implements the ITask interface. Many basic tasks are shipped as part of the .NET Framework,[11] and community developed tasks are freely available. Some examples of Tasks include copying files, creating directories, or parsing XML.
- Properties and Items
- MSBuild provides Properties and Items, which are conceptually equivalent to make's macros. Properties specify static values, whereas Items are usually used to define sets of files or folders on which to perform Tasks. Specifying files on Items is made easy by the support of wildcards.
See also
References
- ^ "Releases · Microsoft/msbuild". GitHub. Microsoft. Retrieved 2018-02-16.
- ^ Microsoft/msbuild. Microsoft. Retrieved 11 March 2018 – via GitHub.
- ^ Hashimi, Sayed Ibrahim; Bartholomew, William (2009). Inside the Microsoft Build Engine: Using MSBuild and Team Foundation Build. Microsoft Press. p. 406. ISBN 978-0-7356-2628-7.
- ^ a b "MSBuild". MSDN. Microsoft. Retrieved 11 December 2013.
- ^ Lander, Rich (18 March 2015). "MSBuild Engine is now Open Source on GitHub". .NET Blog. Microsoft. Retrieved 2018-02-19.
- ^ "What's New in MSBuild 12.0". MSDN. Microsoft. Retrieved 10 March 2014.
- ^ "MSBuild Multitargeting Overview". MSDN. Microsoft. Retrieved 11 December 2013.
- ^ "Building, Testing, and Deployment". What's New in Visual Studio 2005. MSDN. Microsoft. Archived from the original on 2014-08-26.
- ^ Sneath, Tim (July 19, 2004). "MSBuild: The New Build System for Visual Studio 2005 and Longhorn". Tim Sneath. MSDN Blogs. Retrieved 2018-04-22.
- ^ England, Chuck (February 25, 2010). "Getting Started with MSBuild". The Visual Studio Blog. MSDN Blogs. Retrieved 2018-04-22.
- ^ "MSBuild Task Reference". MSDN. Microsoft. Retrieved 11 March 2015.
Further reading
- Kretzler, Brian (2011). MSBuild Trickery: 99 Ways to Bend the Build Engine to Your Will. K Cross Seven Ranch Company. p. 426. ISBN 978-0-615-50907-5.
- Hashimi, Sayed Ibrahim (June 2006). "Inside MSBuild: Compiling Apps With Custom Tasks For The Microsoft Build Engine". MSDN Magazine. Microsoft. Retrieved 11 April 2013.
- Hashimi, Sayed Ibrahim (March 2007). "WiX Tricks: Automate Releases With MSBuild And Windows Installer XML". MSDN Magazine. Microsoft. Retrieved 11 April 2013.
- Hashimi, Sayed Ibrahim (February 2009). "MSBuild: Best Practices For Creating Reliable Builds, Part 1". MSDN Magazine. Microsoft. Retrieved 11 April 2013.
- Hashimi, Sayed Ibrahim (March 2009). "MSBuild: Best Practices For Creating Reliable Builds, Part 2". MSDN Magazine. Microsoft. Retrieved 11 April 2013.
- Reif, Andreas (10 June 2010). "Einführung in Microsofts Build-Management-Technik MSBuild" [Introduction to Microsoft's build management technology, MSBuild]. heise Developer (in German). Heinz Heise. Retrieved 11 April 2013.
- Jones, Mike; Warren, Genevieve; Blome, Mike; Robertson, Colin; Hogenson, Gordon; Cai, Saisang (4 November 2016). "MSBuild Target Framework and Target Platform". Microsoft Docs. Microsoft. Retrieved 2018-02-19.