Running maven from ant
Currently, our pre-staging/production deployment methods are strictly ant based. With development migrating to m2 for building, we no longer have various stack.property files lying around, everything exists in profiles.xml. So what I'd like to do is use the maven ant tasks as defined here: http://maven.apache.org/ant-tasks.html (I've opted for the put the jar in the ant_home\lib directory install option) But, I'm having no success - project name=testprops default=build xmlns:artifact=antlib:org.apache.maven.artifact.ant target name=build artifact:pom id=project file=pom.xml / echo message=${maven.project.version}/ /target /project As just a simple tester, the resulting echo statement is - Buildfile: test.xml mavenrun: [echo] ${maven.project.version} What am I doing wrong?
Running maven from Ant ?
Hi List, Running maven is still pretty slow for me as I have to launch the command-line everytime. It would be nifty to be able to run maven within an ant task, I could then simply input this within the jEdit Ant-runner, running in the same VM, which, when equipped with a rich enough classpath, is running real real quick! Any hope ? Any Maven integration within some IDEs ? Thanks. Paul - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Running maven from Ant ?
On Wed, 2003-07-02 at 11:46, Paul Libbrecht wrote: Running maven is still pretty slow for me as I have to launch the command-line everytime. It would be nifty to be able to run maven within an ant task, I could then simply input this within the jEdit Ant-runner, running in the same VM, which, when equipped with a rich enough classpath, is running real real quick! I extracted the following from the maven.bat/maven startup script. It's a sniplet for ant, possibly it helps --- SNIP --- java classpath=${env.MAVEN_HOME}/lib/forehead-1.0-beta-4.jar classname=com.werken.forehead.Forehead maxmemory=256m failonerror=true fork=true arg value=java:compile / arg value=your_other_second_goal_here / sysproperty key=javax.xml.parsers.SAXParserFactory value=org.apache.xerces.jaxp.SAXParserFactoryImpl / sysproperty key=javax.xml.parsers.DocumentBuilderFactory value=org.apache.xerces.jaxp.DocumentBuilderFactoryImpl/ sysproperty key=java.endorsed.dirs value==${env.JAVA_HOME}/lib/endorsed${path.separator}${env.MAVEN_HOME}/lib/endorsed / sysproperty key=forehead.conf.file value=${env.MAVEN_HOME}/bin/forehead.conf / sysproperty key=tools.jar value=${env.JAVA_HOME}/lib/tools.jar / sysproperty key=maven.home value=${env.MAVEN_HOME} / /java --- SNIP --- Any hope ? Any Maven integration within some IDEs ? There's http://sourceforge.net/projects/mevenide but it looks stalled... Is that projetc dead, Dion? cheers, -- Martin Skopp Riege Software International GmbH Support: mailto:[EMAIL PROTECTED], Information: http://www.riege.com This email is intended to be viewed with a nonproportional font. Public Key on http://www.keyserver.net, Key-ID: 3D4027B5 Fingerprint: 1970 C78D 9A1D 99FA 5CE4 5C0D 29E6 6A95 3D40 27B5 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Running maven from Ant ?
Any Maven integration within some IDEs ? With JBuilder. It is not an integration but you can place yours maven's goal in the tools menu with the tool configuration. Create an new tool for each goal (exemple for java:compile): Program : C:\projet-maven\socle\maven-call.bat Param : java:compile ($ProjectDir) The maven-call.bat script is use because JB8 is lost in directory. Here is its content : cd %2 maven %1 It is not a very clean method but it work Nicolas, - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Running maven from Ant ?
Hi Paul, If you just want an Ant wrapper around maven goals you could use a build.xml like this in the same directory as the project.xml (more or less the ant version of the maven.bat) ?xml version=1.0 encoding=UTF-8 ? project default=maven:site name=startMaven basedir=. property environment=env/ target name=maven:site exec executable=${env.JAVA_HOME}/bin/java.exe dir=${basedir} failonerror=true arg value=-Dmaven.home=${env.MAVEN_HOME} / arg value=-Djavax.xml.parsers.DocumentBuilderFactory=org.apache.xerces.jaxp.Doc umentBuilderFactoryImpl / arg value=-Djavax.xml.parsers.SAXParserFactory=org.apache.xerces.jaxp.SAXParser FactoryImpl / arg value=-Dtools.jar=${env.JAVA_HOME}/lib/tools.jar / arg value=-Dforehead.conf.file=${env.MAVEN_HOME}/bin/forehead.conf / arg value=-Djava.endorsed.dirs=${env.JAVA_HOME}/lib/endorsed;${env.MAVEN_HOME}/ lib/endorsed / arg value=-Xmx160m / arg line=-cp ${env.MAVEN_HOME}/lib/forehead-1.0-beta-4.jar / arg value=com.werken.forehead.Forehead / arg value=site:generate / /exec /target /project -Original Message- From: Paul Libbrecht [mailto:[EMAIL PROTECTED] Sent: Mittwoch, 2. Juli 2003 11:47 To: Maven Users List Subject: Running maven from Ant ? Hi List, Running maven is still pretty slow for me as I have to launch the command-line everytime. It would be nifty to be able to run maven within an ant task, I could then simply input this within the jEdit Ant-runner, running in the same VM, which, when equipped with a rich enough classpath, is running real real quick! Any hope ? Any Maven integration within some IDEs ? Thanks. Paul - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Running maven from Ant ?
Indeed, it may help, But have you attempted without forking ? Some of the parameters of your script seem to be really needing it... On this case is where I would see real advantages in the speed of running... And I do believe, it should be a requirement that maven has a plug to do so at some point. (I have to agree I never found it easy to do it in ant). Paul On Mercredi, juil 2, 2003, at 12:07 Europe/Paris, Martin Skopp wrote: On Wed, 2003-07-02 at 11:46, Paul Libbrecht wrote: Running maven is still pretty slow for me as I have to launch the command-line everytime. It would be nifty to be able to run maven within an ant task, I could then simply input this within the jEdit Ant-runner, running in the same VM, which, when equipped with a rich enough classpath, is running real real quick! I extracted the following from the maven.bat/maven startup script. It's a sniplet for ant, possibly it helps --- SNIP --- java classpath=${env.MAVEN_HOME}/lib/forehead-1.0-beta-4.jar classname=com.werken.forehead.Forehead maxmemory=256m failonerror=true fork=true arg value=java:compile / arg value=your_other_second_goal_here / sysproperty key=javax.xml.parsers.SAXParserFactory value=org.apache.xerces.jaxp.SAXParserFactoryImpl / sysproperty key=javax.xml.parsers.DocumentBuilderFactory value=org.apache.xerces.jaxp.DocumentBuilderFactoryImpl/ sysproperty key=java.endorsed.dirs value==${env.JAVA_HOME}/lib/ endorsed${path.separator}${env.MAVEN_HOME}/lib/endorsed / sysproperty key=forehead.conf.file value=${env.MAVEN_HOME}/bin/forehead.conf / sysproperty key=tools.jar value=${env.JAVA_HOME}/lib/tools.jar / sysproperty key=maven.home value=${env.MAVEN_HOME} / /java --- SNIP --- Any hope ? Any Maven integration within some IDEs ? There's http://sourceforge.net/projects/mevenide but it looks stalled... Is that projetc dead, Dion? cheers, -- Martin Skopp Riege Software International GmbH Support: mailto:[EMAIL PROTECTED], Information: http://www.riege.com This email is intended to be viewed with a nonproportional font. Public Key on http://www.keyserver.net, Key-ID: 3D4027B5 Fingerprint: 1970 C78D 9A1D 99FA 5CE4 5C0D 29E6 6A95 3D40 27B5 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Running maven from Ant ?
Martin Skopp [EMAIL PROTECTED] wrote on 02/07/2003 08:07:42 PM: Any hope ? Any Maven integration within some IDEs ? There's http://sourceforge.net/projects/mevenide but it looks stalled... Is that projetc dead, Dion? Nope, it's not dead. cheers, -- Martin Skopp Riege Software International GmbH Support: mailto:[EMAIL PROTECTED], Information: http://www.riege.com -- dIon Gillard, Multitask Consulting Blog: http://blogs.codehaus.org/people/dion/ Work: http://www.multitask.com.au