Long time ago, i had a post about running Ant in Maven using the maven-antrun-plugin but the Ant script would be attached to the Maven lifecycle phase.
Sometimes you may just want to run a standalone Ant task in Maven without being involved in any lifecycle phase. In that case, you can try configure the maven-antrun-plugin as follow.
<echo message="Hello world"/>
You can run it directly by
Reference: StackOverflow – How to call maven-antrun-plugin target without attach execution to a maven phase ?
I have the following shell script to start the Jetty Server in my portable web application in Windows.
start java -DSTOP.PORT=8080 -DSTOP.KEY=stop_jetty -jar start.jar
Continue reading Maven – Start Jetty Server by Ant task using maven-antrun-plugin
The maven-antrun-plugin allows us to run Ant tasks in Maven. On the contrary, there is no Ant task for running Maven in Ant.
Continue reading Run Maven in Ant
You have to specific the plugin dependency in the pom.xml if u want to use the installer task of AntInstaller in Maven.
Continue reading Maven – Using AntInstaller in Maven
Ant Tasks, such as <if>, belongs to ant-contrib.jar. So in order to use them in maven-antrun-plugin, you have to add this dependency explicitly in the pom.xml.
Continue reading Maven – Add ant-contrib Ant Tasks in maven-antrun-plugin
maven-antrun-plugin allows maven user to add ant tasks in different maven life cycle phases. To use the maven-antrun-plugin, add the following text in the pom.xml.
Continue reading Maven – Using Ant tasks with maven-antrun-plugin