I have many sub modules of php projects which are run using ANT [It just copies files and runs SQL].
Now I need to Implement Maven for handling future Unit Testing + [Maven is the Best tool which we anyway need to use in the future.]
I have installed Maven for php in Eclipse. I have made a new project using Maven in the IDE itself. I can run the Project also.
[I am a noob to Maven but good with ANTs
]
Now I want to call those submodular ANT's xml using the Maven project. There is ANT RUN which does the trick for maven, but I am not able to:
- figure out how to reference modules'
ANT xml
outside the Maven Project. - Ant just merely linking the XML would do the job? Or do I need more dependencies?
Use the Maven ant runner plugin to invoke the ANT logic, using ANT's subant task
Example
pom.xml
ANT is configured to run during the "compile" phase of the Maven build. The ANT logic uses the subant task to run external ANT logic.
Run example
You can simply use ant task inside target configuration element of Maven's Ant Run plugin.