Em Qui, 2004-08-05 Ãs 11:24, Gary Feldman escreveu: > >From: "Rodrigo B. de Oliveira" <[EMAIL PROTECTED]> > >Sent: Wednesday, August 04, 2004 2:02 PM > > > > Hi, I'm migrating an ant based build file to nant. One of the things I > > Rather than looking at various ways of doing this in nant, I think the > better question is why do you want to port an ant build to nant > in the first place? That seems like just make-work. Ant is designed > for building Java systems. NAnt isn't, at least not yet. In other > words, doing this port doesn't really buy you anything that I can see. >
Too little information on my email perhaps? :-) The build is not for a java system of any kind. The first version (ant based) would just copy some files to the appropriate directories, start a python interpreter to do some string replacements and then run jsunit (needs a java vm). It was based on ant because the first developer was more familiar with ant. I was assigned the job of incrementing the build script and decided to organize some of the things I'd need as tasks. I like nant and boo best than ant and java so here am I. BTW, here's what I did based on the suggestions I got (thanks!): <target name="test" depends="all"> <fileset id="classpath" basedir="${jsunit.dir}/results"> <include name="lib/*.jar" /> <include name="bin/jsunit.jar" /> </fileset> <boo> import NAnt.Core.Types import System.IO fs as FileSet = Project.DataTypeReferences["classpath"] Project.Properties["classpath"] = join(fs.FileNames, Path.PathSeparator) </boo> <exec program="java"> <arg value="-cp ${classpath}" /> <arg value="junit.textui.TestRunner" /> <arg value="net.jsunit.StandaloneTest" /> </exec> </target> In a related note I've also came up with this replace task: <replace output-encoding="iso-8859-1"> <fileset basedir="${output}"> <include name="**/*.htm" /> <include name="**/*.html" /> </fileset> <replacements> <replace pattern="(/images/)|(images/)" value="http://${targetserver}/images/" /> <replace pattern="(/js/)|(\bjs/)" value="http://${targetserver}/js/" /> </replacements> </replace> Pretty simple stuff. Cheers, Rodrigo ------------------------------------------------------- This SF.Net email is sponsored by OSTG. Have you noticed the changes on Linux.com, ITManagersJournal and NewsForge in the past few weeks? Now, one more big change to announce. We are now OSTG- Open Source Technology Group. Come see the changes on the new OSTG site. www.ostg.com _______________________________________________ Nant-users mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/nant-users