You'd need an ArtifactFactory and an ArtifactResolver, along with the repository list and the local repository...I think that's it.

Once you have these, you can use the original artifact to create a new one with the "clover" classifier, then feed that into the ArtifactResolver, along with the repositories mentioned above.

I'm currently doing this to locate source archives for the builds of a client...

Let me know if you have trouble.

-john

Vincent Massol wrote:
Here's an update so far (see below).

-----Original Message-----
From: Vincent Massol [mailto:[EMAIL PROTECTED]
Sent: mercredi 5 avril 2006 12:58
To: 'Maven Developers List'
Subject: Feedback needed on clover aggregation feature I'd like to
implement...

Hi,

I've just realized that there's work to be done on the clover plugin if we
want it to support aggregated clover reports. By aggregated reports, I
mean
getting a single report for all modules. Right now this is possible but
each
module will only contribute coverage for its own code. I'd like that
coverage generated by a module on some other module's code also gets
counted.

For this I'm planning to try implementing the following:

* Modify clover:instrument so that the forked lifecycle extends till the
install phase

Done.

BTW we may need 2 goals: instrument and instrumentAndInstall so that
instrument goes till the "test" phase while instrumentAndInstall goes till
the "install" phase.
* Create an internal clover mojo bound to the install phase that will
created a clovered version of the project's artifact as an attached
artifact
(classifier = "clover").

Not needed actually.

* Handle the different type of packaging. For example for a WAR packaging,
add the clover jar to the attached clovered WAR, etc.

Done automatically as we're adding the clover dep to the list of deps in the
instrument mojo...
* Modify the clover:instrumentInternal so that for any dependency
artifact,
it looks for the clovered version in the repo and adds it instead of the
non-clovered version.

This is where I'm stuck right now. Not sure how to do this yet. If anyone
knows how to find an attached artifact once you have the main artifact
object that would be nice.
As this is pretty involved I'd like to be sure this is the right thing to
do.

Thanks
-Vincent


        

        
                
___________________________________________________________________________ Nouveau : téléphonez moins cher avec Yahoo! Messenger ! Découvez les tarifs exceptionnels pour appeler la France et l'international.
Téléchargez sur http://fr.messenger.yahoo.com

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



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

Reply via email to