[ http://jira.codehaus.org/browse/MPMULTIPROJECT-58?page=all ]
     
Lukas Theussl closed MPMULTIPROJECT-58:
---------------------------------------

    Resolution: Fixed

> Possibllity to re-execute multiproject:projects-init
> ----------------------------------------------------
>
>          Key: MPMULTIPROJECT-58
>          URL: http://jira.codehaus.org/browse/MPMULTIPROJECT-58
>      Project: maven-multiproject-plugin
>         Type: Improvement
>     Versions: 1.4.1
>  Environment: windowsXP
>     Reporter: Lucas Persson
>      Fix For: 1.5
>  Attachments: MPMULTIPROJECT-58.txt
>
>
> If a custom goal is defined which wants to call the multiproject plugin twice 
> with different  value on
> the maven.multiproject.includes property the goal multiproject:projects-init 
> must be executed twice.
> Example:
>     <goal name="release-ejb-client">
>       <!-- dummy call to init the plugin -->
>       <attainGoal name="maven-multiproject-plugin:register"/>
>       <maven:set plugin="maven-multiproject-plugin" 
>               property="maven.multiproject.includes" 
>               value="${my.ejb.clients}"/>
>       <maven:set plugin="maven-multiproject-plugin" 
>               property="goal" 
>               value="ejb:deploy-client"/>
>               <attainGoal name="multiproject:goal"/>
>         <!-- call the nultiproject plugin again but with a different list -->
>       <maven:set plugin="maven-multiproject-plugin" 
>               property="maven.multiproject.includes" 
>               value="${my.ejb.clients.src}"/>
>       <maven:set plugin="maven-multiproject-plugin" 
>               property="goal" 
>               value="dist:deploy-src"/>
>               <attainGoal name="multiproject:goal"/>
>     </goal>
> The first list will be used in the second call to the plugin since there is a 
> flag in multiproject:projects-init
> that  prevents the goal being runned twice.
> What I want to add is the possibillity to force the execution of 
> multiproject:projects-init. For instance like this:
>     <goal name="release-ejb-client">
>       <!-- dummy call to init the plugin -->
>       <attainGoal name="maven-multiproject-plugin:register"/>
>       <maven:set plugin="maven-multiproject-plugin" 
>               property="maven.multiproject.includes" 
>               value="${my.ejb.clients}"/>
>       <maven:set plugin="maven-multiproject-plugin" 
>               property="goal" 
>               value="ejb:deploy-client"/>
>               <attainGoal name="multiproject:goal"/>
>         <!-- call the nultiproject plugin again but with a different list 
>                 Fist force the multiproject:projects-init to be executed.
>          -->
>       <maven:set plugin="maven-multiproject-plugin" 
>               property="mpprojectsInit" 
>               value="false"/>
>       <maven:set plugin="maven-multiproject-plugin" 
>               property="maven.multiproject.includes" 
>               value="${my.ejb.clients.src}"/>
>       <maven:set plugin="maven-multiproject-plugin" 
>               property="goal" 
>               value="dist:deploy-src"/>
>               <attainGoal name="multiproject:goal"/>
>     </goal>
> The new  multiproject:projects-init will look like this:
>   <goal name="multiproject:projects-init">
>     <j:if test="${mpprojectsInit == null || mpprojectsInit == false}">
>       <j:set var="mpprojectsInit" value="true" />
>       <ant:echo>Gathering project list</ant:echo>
>       <maven:reactor
>         basedir="${maven.multiproject.basedir}"
>         banner="Gathering project list"
>         includes="${maven.multiproject.includes}"
>         excludes="${maven.multiproject.excludes}"
>         postProcessing="true"
>         collectOnly="true"
>         collectionVar="multiprojects"
>         ignoreFailures="${maven.multiproject.ignoreFailures}"
>       />
>     </j:if>
>   </goal>

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to