Mon, 10. May 2004
I've talked about that little pet library of mine every now and then, and think it is time to give others a chance to look at it.
The thing I'm talking about is a small Ant task library that should work with Ant 1.6.x and provides three tasks:
- <dotnetexec> - a cousin of <exec> and in fact it will do the same as <exec> when you use Microsoft's CLR. On Linux though, it will default to use Mono and you don't have to say so explicitly, just specify the assembly as executable. There also is an attribute to give you more control in case you want to run Rotor or Mono on Windows for example.
- <nant> - run NAnt from within Ant. Usage ranges from running an existing build file to specifying the NAnt build file in-line.
<nant> <build> <nunit2> <formatter type="Plain"/> <test assemblyname="MyProject.Tests.dll" appconfig="MyProject.Tests.dll.config"/> </nunit2> </build> </nant>
runs NAnt's NUnit task from within Ant. This is supposed to work transparently using Mono or Microsoft's CLR. - <msbuild> - similar to <nant> but for MSBuild. This is probably not going to work at all, but I wanted to include it anyway. In particular nested build files won't work since Ant insists on lower-casing everything before it passes it to the task.
All of these tasks have only been tested using Mono on Linux and MacOS X so far. The docs are online - also as an archive. An Ant 1.6.x compatible antlib is here..
The CVS HEAD version contains a WiX task as well, but I'm not sure about its current shape, so I've left it out for now.
Any feedback is appreciated.
path: /en/Apache/Ant/dotnet | #