How do you force maven to execute antrun:run task after all the package tasks in a POM with child modules?
-
I have a parent POM with a bunch of child modules. I want to run an antrun:run task after all the children have executed a package task (I'm using Ant to package my app since i gave up figuring out how to get assembly to work correctly). I need to have the antrun task execute *after* all the children - but I can't associate it with package phase since parent gets "packaged" before children, and i need ant to run afterwards. Is there a way to do it in one command? Easy workaround, of course, is to run 2 maven commands, but i want to do it in one, if possible.
-
Answer:
People on StackOverflow ended up being faster and brighter: http://stackoverflow.com/questions/3375574/how-do-you-force-maven-to-execute-antrunrun-task-after-all-the-package-tasks-in The key is to have another subproject that does all the relevant antrun:run packaging, and have that be at the end of your modules. While not the most maveny way, it certainly works quite well. yay!
Toli Kuznets at Quora Visit the source
Related Q & A:
- What is a Windows 8 'Child Session?Best solution by Stack Overflow
- How can I force the login to a specific ip address?Best solution by Stack Overflow
- How to run an interactive batch file on windows from a service?Best solution by Stack Overflow
- How old do you have to be to run a non-profit organization?Best solution by Yahoo! Answers
- What are the tasks of a Registered Nurse [RN]?Best solution by Yahoo! Answers
Just Added Q & A:
- How many active mobile subscribers are there in China?Best solution by Quora
- How to find the right vacation?Best solution by bookit.com
- How To Make Your Own Primer?Best solution by thekrazycouponlady.com
- How do you get the domain & range?Best solution by ChaCha
- How do you open pop up blockers?Best solution by Yahoo! Answers
For every problem there is a solution! Proved by Solucija.
-
Got an issue and looking for advice?
-
Ask Solucija to search every corner of the Web for help.
-
Get workable solutions and helpful tips in a moment.
Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.