You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by David Weintraub <qa...@gmail.com> on 2008/10/24 01:16:08 UTC

Calling Maven in Ant

Okay, without using the <exec> task, how do I call a Maven task from Ant?

I have a pom.xml, so all I want to do is say something like:

<maven dir="${prog.dir}" pom="pom.xml" step="package"/>

I looked over the Maven Ant tasks that are in Maven, and they look
overly complex for what I want. They look like they define the whole
dependency relationship that's already in the pom.xml. I already have
a pom.xml, and simply want to execute Maven from Ant.

So, what is the best way of calling Maven from Ant?

--
David Weintraub
qazwart@gmail.com

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


AW: Calling Maven in Ant

Posted by Ja...@rzf.fin-nrw.de.
The Maven tasks in Maven should make Ant to do some Maven stuff, so the way inverse.

If the <exec> way works you could define a Makro for invoking with that signature.
You could also use <java> in that makro instead of <exec>.


Jan

>-----Ursprüngliche Nachricht-----
>Von: David Weintraub [mailto:qazwart@gmail.com] 
>Gesendet: Freitag, 24. Oktober 2008 01:16
>An: Ant Users List
>Betreff: Calling Maven in Ant
>
>Okay, without using the <exec> task, how do I call a Maven 
>task from Ant?
>
>I have a pom.xml, so all I want to do is say something like:
>
><maven dir="${prog.dir}" pom="pom.xml" step="package"/>
>
>I looked over the Maven Ant tasks that are in Maven, and they look
>overly complex for what I want. They look like they define the whole
>dependency relationship that's already in the pom.xml. I already have
>a pom.xml, and simply want to execute Maven from Ant.
>
>So, what is the best way of calling Maven from Ant?
>
>--
>David Weintraub
>qazwart@gmail.com
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
>For additional commands, e-mail: user-help@ant.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org