[ http://jira.codehaus.org/browse/MCLOVER-59?page=comments#action_78744 ] 
            
Vincent Massol commented on MCLOVER-59:
---------------------------------------

Thanks Chris.

I was able to reproduce the problem. I've looked at the clover plugin source 
code and I see that I'm setting the finalName there:

{code:java}
getProject().getBuild().setFinalName( getProject().getArtifactId() + "-" + 
getProject().getVersion() + "-clover" );
{code}

Looks to me like a potential bug in m2 but it needs to be debugged further. If 
you have any idea on what's going on please let me know...

I think it's possible that the finalName is set correctly on the Project object 
but not when interpolating properties from the pom.xml. I believe most plugins 
will work just fine as they use the internal Project object. If you use the 
AntRun plugin though and you're using project.build.finalName in there it'll 
fail. We need to find out why...

Thanks
-Vincent

> project.build.finalName incorrect in forked lifecycle
> -----------------------------------------------------
>
>                 Key: MCLOVER-59
>                 URL: http://jira.codehaus.org/browse/MCLOVER-59
>             Project: Maven 2.x Clover Plugin
>          Issue Type: Bug
>            Reporter: Chris Tucker
>         Assigned To: Vincent Massol
>            Priority: Critical
>
> The project.build.finalName property is not correctly redefined in the forked 
> lifecycle to include the -clover classifier.  This can be verified by 
> attaching an ant-run execution to the build as:
> <plugin>
>       <artifactId>maven-antrun-plugin</artifactId>
>       <executions>
>               <execution>
>                       <id>normal</id>
>                       <phase>generate-resources</phase>
>                       <configuration>
>                               <tasks>
>                                       <echo
>                                               
> message="${project.build.finalName}" />
>                               </tasks>
>                       </configuration>
>                       <goals>
>                               <goal>run</goal>
>                       </goals>
>               </execution>
>       </executions>
> </plugin>
> Note that in both executions of the build (original and forked) 
> project.build.finalName evaluates to the same value.  Also note that 
> help:effective-pom will replace project.build.finalName with the actual value 
> (e.g. myartifact-1.0-SNAPSHOT) where it'll leave other properties (like 
> ${project.build.directory}) in the named-variable form.
> Having the finalName incorrect makes it impossible to use clover with 
> generated resources going directly into the target directory structure, so 
> this is a blocker on getting clover working with builds of this type.

-- 
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

        

Reply via email to