You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

index.html 15 kB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338
  1. <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
  2. <!--
  3. Licensed to the Apache Software Foundation (ASF) under one or more
  4. contributor license agreements. See the NOTICE file distributed with
  5. this work for additional information regarding copyright ownership.
  6. The ASF licenses this file to You under the Apache License, Version 2.0
  7. (the "License"); you may not use this file except in compliance with
  8. the License. You may obtain a copy of the License at
  9. http://www.apache.org/licenses/LICENSE-2.0
  10. Unless required by applicable law or agreed to in writing, software
  11. distributed under the License is distributed on an "AS IS" BASIS,
  12. WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  13. See the License for the specific language governing permissions and
  14. limitations under the License.
  15. -->
  16. <html lang="en">
  17. <!-- GENERATED FILE, DO NOT EDIT, EDIT THE XML FILE IN xdocs INSTEAD! -->
  18. <head>
  19. <META http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
  20. <title>Apache Ant - Apache .NET Ant Library</title>
  21. <link type="text/css" href="../../page.css" rel="stylesheet">
  22. </head>
  23. <body>
  24. <p class="navpath">
  25. <script src="../../breadcrumbs.js" language="JavaScript" type="text/javascript"></script>
  26. </p>
  27. <div class="logobar">
  28. <table width="100%" border="0" cellspacing="0" cellpadding="0">
  29. <tr>
  30. <td align="left"><img border="0" alt="Apache Ant site" src="../../images/group-logo.gif"></td>
  31. <td align="center" width="100%"><img alt="Apache Ant logo" border="0" src="../../images/project-logo.gif"></td>
  32. <td align="right">
  33. <form target="_blank" onsubmit="q.value = query.value + ' site:ant.apache.org'" action="http://www.google.com/search" method="get">
  34. <table summary="search" border="0" cellspacing="0" cellpadding="0" bgcolor="#4C6C8F">
  35. <tr>
  36. <td colspan="3"><img height="10" width="1" alt="" src="../../images/spacer.gif"></td>
  37. </tr>
  38. <tr>
  39. <td><img height="1" width="1" alt="" src="../../images/spacer.gif"></td>
  40. <td nowrap="nowrap" class="searchcaption">
  41. <input name="q" type="hidden">
  42. <input size="15" id="query" type="text">
  43. <img height="1" width="5" alt="" src="../../images/spacer.gif">
  44. <input name="Search" value="Search" type="submit">
  45. <br>
  46. the Apache Ant site
  47. </td>
  48. <td><img height="1" width="1" alt="" src="../../images/spacer.gif"></td>
  49. </tr>
  50. <tr>
  51. <td><img alt="" border="0" height="10" width="9" src="../../images/search-left.gif"></td>
  52. <td><img height="1" width="1" alt="" src="../../images/spacer.gif"></td>
  53. <td><img alt="" border="0" height="10" width="9" src="../../images/search-right.gif"></td>
  54. </tr>
  55. </table>
  56. </form>
  57. </td>
  58. </tr>
  59. </table>
  60. </div>
  61. <div class="tab">
  62. <table summary="tab bar" border="0" cellpadding="0" cellspacing="0">
  63. <tr>
  64. <td width="5"><img alt="" height="8" width="8" src="../../images/spacer.gif"></td><td valign="bottom">
  65. <table summary="non selected tab" style="height: 1.4em" border="0" cellpadding="0" cellspacing="0">
  66. <tr>
  67. <td valign="top" width="5" bgcolor="#B2C4E0"><img height="5" width="5" alt="" src="../../images/tab-left.gif"></td><td valign="middle" bgcolor="#B2C4E0"><a href="../../index.html"><font size="2" face="Arial, Helvetica, Sans-serif">Home</font></a></td><td valign="top" width="5" bgcolor="#B2C4E0"><img height="5" width="5" alt="" src="../../images/tab-right.gif"></td>
  68. </tr>
  69. </table>
  70. </td>
  71. <td width="8"><img alt="" height="5" width="8" src="../../images/spacer.gif"></td><td valign="bottom">
  72. <table summary="selected tab" style="height: 1.5em" border="0" cellpadding="0" cellspacing="0">
  73. <tr>
  74. <td valign="top" width="5" bgcolor="#4C6C8F"><img height="5" width="5" alt="" src="../../images/tabSel-left.gif"></td><td valign="middle" bgcolor="#4C6C8F"><font color="#ffffff" size="2" face="Arial, Helvetica, Sans-serif"><b>Projects</b></font></td><td valign="top" width="5" bgcolor="#4C6C8F"><img height="5" width="5" alt="" src="../../images/tabSel-right.gif"></td>
  75. </tr>
  76. </table>
  77. </td>
  78. </tr>
  79. </table>
  80. </div>
  81. <div class="bluebar"></div>
  82. <div class="menucontainer">
  83. <div class="menu">
  84. <ul>
  85. <li class="menuheader">Projects
  86. <ul>
  87. <li>
  88. <a href="../../projects/index.html">Welcome</a>
  89. </li>
  90. </ul>
  91. </li>
  92. <li class="menuheader">Apache Ant Libraries
  93. <ul>
  94. <li>
  95. <a href="../../antlibs/index.html">Introduction</a>
  96. </li>
  97. <li>
  98. <a href="../../antlibs/charter.html">Charter</a>
  99. </li>
  100. <li>
  101. <a href="../../antlibs/proper.html">Ant Libraries</a>
  102. </li>
  103. <li>
  104. <a href="../../antlibs/sandbox.html">Sandbox Ant Libraries</a>
  105. </li>
  106. <li>
  107. <a href="http://ant.apache.org/antlibs/bindownload.cgi">Binary Distributions</a>
  108. </li>
  109. <li>
  110. <a href="http://ant.apache.org/antlibs/srcdownload.cgi">Source Distributions</a>
  111. </li>
  112. </ul>
  113. </li>
  114. <li class="menuheader">Apache Ivy
  115. <ul>
  116. <li>
  117. <a href="../../projects/ivy.html">Introduction</a>
  118. </li>
  119. <li>
  120. <a href="http://ant.apache.org/ivy/">Homepage</a>
  121. </li>
  122. <li>
  123. <a href="http://ant.apache.org/ivy/download.cgi">Distributions</a>
  124. </li>
  125. <li>
  126. <a href="http://cwiki.apache.org/IVY/">Wiki</a>
  127. </li>
  128. </ul>
  129. </li>
  130. <li class="menuheader">Apache IvyDE
  131. <ul>
  132. <li>
  133. <a href="../../projects/ivyde.html">Introduction</a>
  134. </li>
  135. <li>
  136. <a href="http://ant.apache.org/ivy/ivyde">Homepage</a>
  137. </li>
  138. <li>
  139. <a href="http://ant.apache.org/ivy/ivyde/screenshots.html">Screenshots</a>
  140. </li>
  141. <li>
  142. <a href="http://ant.apache.org/ivy/ivyde/download.cgi">Distributions</a>
  143. </li>
  144. </ul>
  145. </li>
  146. </ul>
  147. </div>
  148. <center>
  149. <a href="http://www.apache.org/events/current-event.html"><img border="0" title="ApacheCon" alt="ApacheCon - logo" src="http://www.apache.org/events/current-event-125x125.png" style="width: 125px;height: 125px;"></a>
  150. </center>
  151. <img style="float: left" height="10" width="10" border="0" alt="" src="../../images/menu-left.gif">
  152. <img style="float: right" height="10" width="10" border="0" alt="" src="../../images/menu-right.gif">
  153. </div>
  154. <div class="lightbluebar">&nbsp;</div>
  155. <div class="main">
  156. <div class="content">
  157. <h1 class="title">Apache .NET Ant Library</h1>
  158. <h3 class="section">
  159. <a name="Apache .NET Ant Library&amp;#x2122;"></a>
  160. Apache .NET Ant Library&#x2122;
  161. </h3>
  162. <p>The Apache .NET Antlib provides tasks that support
  163. development of .NET software with Apache Ant.</p>
  164. <h3 class="section">
  165. <a name="Apache .NET Ant Library 1.1"></a>
  166. Apache .NET Ant Library 1.1
  167. </h3>
  168. <h3>February 4, 2011 - Apache .NET Ant Library 1.1
  169. Available</h3>
  170. <p>Apache .NET Ant Library 1.1 is now available for
  171. download as <a href="http://ant.apache.org/antlibs/bindownload.cgi">binary</a>
  172. or <a href="http://ant.apache.org/antlibs/srcdownload.cgi">source</a>
  173. release.</p>
  174. <p>This release fixes a few bugs and adds new tasks for the
  175. F# compiler and the tallow tool of the WiX toolkit.</p>
  176. <h3 class="section">
  177. <a name="Idea"></a>
  178. Idea
  179. </h3>
  180. <p>This library doesn't strive to replace NAnt or MSBuild, its
  181. main purpose is to help those of us who work on projects
  182. crossing platform boundaries. With this library you can use Ant
  183. to build and test the Java as well as the .NET parts of your
  184. project.</p>
  185. <p>This library provides a special version of the
  186. <code>&lt;exec&gt;</code> task tailored to run .NET executables.
  187. On Windows it will assume the Microsoft framework is around and
  188. run the executable directly, while it will invoke Mono on any
  189. other platform. Of course you can override these
  190. assumptions.</p>
  191. <p>Based on this a few tasks to run well known .NET utilities
  192. from within Ant are provided, namely tasks to run <a href="http://www.nunit.org/">NUnit</a>, <a href="http://nant.sf.net/">NAnt</a>, <a href="http://forums.microsoft.com/MSDN/ShowForum.aspx?ForumID=27&amp;SiteID=1">MSBuild</a>
  193. and the <a href="http://wix.sf.net/">Wix</a> toolkit.</p>
  194. <p>The initial .NET tasks of Ant (compiler tasks for C#, J# and VB.NET
  195. for example) have also been moved to this Antlib and will see further
  196. development here.</p>
  197. <h3 class="section">
  198. <a name="Tasks"></a>
  199. Tasks
  200. </h3>
  201. <h4 class="subsection">
  202. <a name="dotnetexec"></a>
  203. dotnetexec
  204. </h4>
  205. <p>Runs a .NET executable.</p>
  206. <h4 class="subsection">
  207. <a name="nunit"></a>
  208. nunit
  209. </h4>
  210. <p>Runs NUnit tests.</p>
  211. <h4 class="subsection">
  212. <a name="nant"></a>
  213. nant
  214. </h4>
  215. <p>Invokes NAnt, either on an external file or a build file
  216. snippet contained inside your Ant build file.</p>
  217. <h4 class="subsection">
  218. <a name="msbuild"></a>
  219. msbuild
  220. </h4>
  221. <p>Invokes MSBuild, either on an external file or a build file
  222. snippet contained inside your Ant build file.</p>
  223. <h4 class="subsection">
  224. <a name="wix"></a>
  225. wix
  226. </h4>
  227. <p>Invokes the candle and light executables of the WiX toolkit
  228. in order to create MSI installers from within Ant.</p>
  229. <h3 class="section">
  230. <a name="Examples"></a>
  231. Examples
  232. </h3>
  233. <h4 class="subsection">
  234. <a name="nant"></a>
  235. nant
  236. </h4>
  237. <pre class="code">
  238. &lt;project xmlns:dn=&quot;antlib:org.apache.ant.dotnet&quot;&gt;
  239. &lt;dn:nant&gt;
  240. &lt;build&gt;
  241. &lt;echo message=&quot;Hello world&quot;/&gt;
  242. &lt;/build&gt;
  243. &lt;/dn:nant&gt;
  244. &lt;/project&gt;
  245. </pre>
  246. <p>runs NAnt on the embedded <code>&lt;echo&gt;</code>
  247. task, output looks like</p>
  248. <pre class="code">
  249. Buildfile: test.xml
  250. [dn:nant] NAnt 0.85 (Build 0.85.1932.0; rc3; 16.04.2005)
  251. [dn:nant] Copyright (C) 2001-2005 Gerry Shaw
  252. [dn:nant] http://nant.sourceforge.net
  253. [dn:nant]
  254. [dn:nant] Buildfile: file:///c:/DOKUME~1/STEFAN~1.BOD/LOKALE~1/Temp/build1058451555.xml
  255. [dn:nant] Target framework: Microsoft .NET Framework 1.1
  256. [dn:nant]
  257. [dn:nant] [echo] Hello world
  258. [dn:nant]
  259. [dn:nant] BUILD SUCCEEDED
  260. [dn:nant]
  261. [dn:nant] Total time: 0.2 seconds.
  262. BUILD SUCCESSFUL
  263. Total time: 2 seconds</pre>
  264. <h4 class="subsection">
  265. <a name="msbuild"></a>
  266. msbuild
  267. </h4>
  268. <pre class="code">
  269. &lt;project xmlns:dn=&quot;antlib:org.apache.ant.dotnet&quot;&gt;
  270. &lt;dn:msbuild&gt;
  271. &lt;build&gt;
  272. &lt;Message Text=&quot;Hello world&quot;
  273. xmlns=&quot;http://schemas.microsoft.com/developer/msbuild/2003&quot;/&gt;
  274. &lt;/build&gt;
  275. &lt;/dn:msbuild&gt;
  276. &lt;/project&gt;</pre>
  277. <p>runs MSBuild on the embedded <code>&lt;Message&gt;</code>
  278. task, output looks like</p>
  279. <pre class="code">
  280. Buildfile: test.xml
  281. [dn:msbuild] Microsoft (R) Build Engine Version 2.0.50727.42
  282. [dn:msbuild] [Microsoft .NET Framework, Version 2.0.50727.42]
  283. [dn:msbuild] Copyright (C) Microsoft Corporation 2005. All rights reserved.
  284. [dn:msbuild] Build started 15.12.2005 20:21:56.
  285. [dn:msbuild] __________________________________________________
  286. [dn:msbuild] Project &quot;c:\Dokumente und Einstellungen\stefan.bodewig\Lokale Einstellungen\Temp\build1543310185.xml&quot; (default targets):
  287. [dn:msbuild] Target generated-by-ant:
  288. [dn:msbuild] Hello world
  289. [dn:msbuild] Build succeeded.
  290. [dn:msbuild] 0 Warning(s)
  291. [dn:msbuild] 0 Error(s)
  292. [dn:msbuild] Time Elapsed 00:00:00.10
  293. BUILD SUCCESSFUL
  294. Total time: 0 seconds
  295. </pre>
  296. </div>
  297. </div>
  298. <p class="copyright">
  299. Apache Ant, Apache Ivy, Ant, Ivy, Apache, the Apache feather logo, and the Apache Ant project logos are trademarks of The Apache Software Foundation.
  300. <script type="text/javascript" language="JavaScript"><!--
  301. document.write(" - "+"Last Published: " + document.lastModified);
  302. // -->
  303. </script>
  304. </p>
  305. </body>
  306. </html>