Re: Running antrun plugin twice in same phase with another plugin in between?
That would mean I would have to call maven plugins from inside the maven antrun plugin. Seems odd and no idea if that is even possible? 2010/7/15 Ron Wheeler > Can't you order the tasks inside Ant? > > Ron > > On 15/07/2010 2:31 AM, Wim Deblauwe wrote: > >> I do not think this really a big improvement. In my usecase, I need to do >> 4 >> things in a defined order in the after-package, so you are just moving the >> problem. A real ordering of plugin execution during the phases is what I >> really need. I admit that I just recently had a need for it after using >> Maven 2 for more then 2 years on various (big) projects, so it is rare I >> think that you need it, but if you do, you *really* need it. >> >> 2010/7/14 Gorham-Engard, Frank >> >> Hello users, >>> I have an alternate suggestion to the phase/goal ordering issues that are >>> often raised here. >>> Allow for the specification of to include a 'before-' or 'after-' >>> prefix. >>> Users could specify the for a plugin execution to be, for >>> example, >>> 'before-deploy' or 'after-package'. This wouldn't break the life-cycle >>> model >>> while permitting a constrained method for expanding it. >>> Also, any 'after-' phases should be executed when the phase is the >>> target. >>> For example, if I specified a plugin for 'after-deploy' it would be >>> executed >>> (at the end) when the command line was 'mvn deploy'. >>> Perhaps even 'before-before-test' should be allowed as well? But not >>> 'before-after-test', let's not go there! >>> >>> >> From: Wim Deblauwe [mailto:wim.debla...@gmail.com] >>> Sent: Tuesday, July 13, 2010 5:10 AM >>> To: Maven Users List >>> Subject: Running antrun plugin twice in same phase with another plugin in >>> between? >>> >>> Hi, >>> >>> I need to run the antrun plugin twice in the packaging phase. I found >>> this >>> on the wiki: >>> http://docs.codehaus.org/display/MAVENUSER/MiniGuide-AntMultiPhase >>> >>> However, it speaks of different lifecycle phases. I tried with the same >>> phase and that works, however, I need to run another plugin in between. >>> Is >>> this possible? >>> >>> I was hoping that all plugins' executions would be sorted by their id. >>> That >>> way, i could use id's like 'step-1-do-something', >>> 'step-2-do-something-else', to force a certain order of plugin execution. >>> >>> regards, >>> >>> Wim >>> >>> > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > >
Re: Running antrun plugin twice in same phase with another plugin in between?
Can't you order the tasks inside Ant? Ron On 15/07/2010 2:31 AM, Wim Deblauwe wrote: I do not think this really a big improvement. In my usecase, I need to do 4 things in a defined order in the after-package, so you are just moving the problem. A real ordering of plugin execution during the phases is what I really need. I admit that I just recently had a need for it after using Maven 2 for more then 2 years on various (big) projects, so it is rare I think that you need it, but if you do, you *really* need it. 2010/7/14 Gorham-Engard, Frank Hello users, I have an alternate suggestion to the phase/goal ordering issues that are often raised here. Allow for the specification of to include a 'before-' or 'after-' prefix. Users could specify the for a plugin execution to be, for example, 'before-deploy' or 'after-package'. This wouldn't break the life-cycle model while permitting a constrained method for expanding it. Also, any 'after-' phases should be executed when the phase is the target. For example, if I specified a plugin for 'after-deploy' it would be executed (at the end) when the command line was 'mvn deploy'. Perhaps even 'before-before-test' should be allowed as well? But not 'before-after-test', let's not go there!
Re: Running antrun plugin twice in same phase with another plugin in between?
I do not think this really a big improvement. In my usecase, I need to do 4 things in a defined order in the after-package, so you are just moving the problem. A real ordering of plugin execution during the phases is what I really need. I admit that I just recently had a need for it after using Maven 2 for more then 2 years on various (big) projects, so it is rare I think that you need it, but if you do, you *really* need it. 2010/7/14 Gorham-Engard, Frank > Hello users, > I have an alternate suggestion to the phase/goal ordering issues that are > often raised here. > Allow for the specification of to include a 'before-' or 'after-' > prefix. > Users could specify the for a plugin execution to be, for example, > 'before-deploy' or 'after-package'. This wouldn't break the life-cycle model > while permitting a constrained method for expanding it. > Also, any 'after-' phases should be executed when the phase is the target. > For example, if I specified a plugin for 'after-deploy' it would be executed > (at the end) when the command line was 'mvn deploy'. > Perhaps even 'before-before-test' should be allowed as well? But not > 'before-after-test', let's not go there! > > From: Wim Deblauwe [mailto:wim.debla...@gmail.com] > Sent: Tuesday, July 13, 2010 5:10 AM > To: Maven Users List > Subject: Running antrun plugin twice in same phase with another plugin in > between? > > Hi, > > I need to run the antrun plugin twice in the packaging phase. I found this > on the wiki: > http://docs.codehaus.org/display/MAVENUSER/MiniGuide-AntMultiPhase > > However, it speaks of different lifecycle phases. I tried with the same > phase and that works, however, I need to run another plugin in between. Is > this possible? > > I was hoping that all plugins' executions would be sorted by their id. That > way, i could use id's like 'step-1-do-something', > 'step-2-do-something-else', to force a certain order of plugin execution. > > regards, > > Wim >
RE: Running antrun plugin twice in same phase with another plugin in between?
Hello users, I have an alternate suggestion to the phase/goal ordering issues that are often raised here. Allow for the specification of to include a 'before-' or 'after-' prefix. Users could specify the for a plugin execution to be, for example, 'before-deploy' or 'after-package'. This wouldn't break the life-cycle model while permitting a constrained method for expanding it. Also, any 'after-' phases should be executed when the phase is the target. For example, if I specified a plugin for 'after-deploy' it would be executed (at the end) when the command line was 'mvn deploy'. Perhaps even 'before-before-test' should be allowed as well? But not 'before-after-test', let's not go there!
Re: Running antrun plugin twice in same phase with another plugin in between?
I had a look at the maven 2.2.x code and I created a small patch that does it. See http://jira.codehaus.org/browse/MNG-4727 All the patch does is sorting the 'MojoExecution' classes based on their id. It is very few lines of code really. It is a bit hackish as you need to use "step-" in your declaration, but it works perfectly. I hope the maven devs will pick it up under some form or another. regards, Wim 2010/7/13 Wayne Fay > > However, it speaks of different lifecycle phases. I tried with the same > > phase and that works, however, I need to run another plugin in between. > Is > > this possible? > > You could: > release the maven-antrun-plugin under your own artifactId, say > wim-antrun-plugin > then use (in order): m-antrun-p, plugin2, w-antrun-p in your pom > > But this seems like a lot of extra work to me. > > Wayne > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > >
Re: Running antrun plugin twice in same phase with another plugin in between?
> However, it speaks of different lifecycle phases. I tried with the same > phase and that works, however, I need to run another plugin in between. Is > this possible? You could: release the maven-antrun-plugin under your own artifactId, say wim-antrun-plugin then use (in order): m-antrun-p, plugin2, w-antrun-p in your pom But this seems like a lot of extra work to me. Wayne - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Running antrun plugin twice in same phase with another plugin in between?
You can't do this. On 7/13/10 5:09 AM, Wim Deblauwe wrote: > Hi, > > I need to run the antrun plugin twice in the packaging phase. I found this > on the wiki: > http://docs.codehaus.org/display/MAVENUSER/MiniGuide-AntMultiPhase > > However, it speaks of different lifecycle phases. I tried with the same > phase and that works, however, I need to run another plugin in between. Is > this possible? > > I was hoping that all plugins' executions would be sorted by their id. That > way, i could use id's like 'step-1-do-something', > 'step-2-do-something-else', to force a certain order of plugin execution. > > regards, > > Wim > - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Re : Running antrun plugin twice in same phase with another plugin in between?
Hi Julien, yes, I tried that too and it does not work. task1 does not get executed :( regards, Wim 2010/7/13 Julien HENRY > Hi, > > Have you tried the following configuration? > > > > >maven-antrun-plugin > > >task1 >yourphase > > > > > > > run > > > > > >your middle plugin > > >task2 >yourphase > > ... > > > ... > > > > > >maven-antrun-plugin > > >task3 >yourphase > > > > > > > run > > > > > > > I have not tested so I'm not sure it will work. > > Regards, > > Julien > > > > - Message d'origine > > De : Wim Deblauwe > > À : Maven Users List > > Envoyé le : Mar 13 juillet 2010, 11h 09min 36s > > Objet : Running antrun plugin twice in same phase with another plugin in > >between? > > > > Hi, > > > > I need to run the antrun plugin twice in the packaging phase. I found > this > > on the wiki: > > http://docs.codehaus.org/display/MAVENUSER/MiniGuide-AntMultiPhase > > > > However, it speaks of different lifecycle phases. I tried with the same > > phase and that works, however, I need to run another plugin in between. > Is > > this possible? > > > > I was hoping that all plugins' executions would be sorted by their id. > That > > way, i could use id's like 'step-1-do-something', > > 'step-2-do-something-else', to force a certain order of plugin > execution. > > > > regards, > > > > Wim > > > > > > > - > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > >
Re : Running antrun plugin twice in same phase with another plugin in between?
Hi, Have you tried the following configuration? maven-antrun-plugin task1 yourphase run your middle plugin task2 yourphase ... ... maven-antrun-plugin task3 yourphase run I have not tested so I'm not sure it will work. Regards, Julien - Message d'origine > De : Wim Deblauwe > À : Maven Users List > Envoyé le : Mar 13 juillet 2010, 11h 09min 36s > Objet : Running antrun plugin twice in same phase with another plugin in >between? > > Hi, > > I need to run the antrun plugin twice in the packaging phase. I found this > on the wiki: > http://docs.codehaus.org/display/MAVENUSER/MiniGuide-AntMultiPhase > > However, it speaks of different lifecycle phases. I tried with the same > phase and that works, however, I need to run another plugin in between. Is > this possible? > > I was hoping that all plugins' executions would be sorted by their id. That > way, i could use id's like 'step-1-do-something', > 'step-2-do-something-else', to force a certain order of plugin execution. > > regards, > > Wim > - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org