I am having trouble getting artifacts from my project. I would like to
retrieve the dependencies to add to a classpath passed to another module
I am calling. I looked at other plugins such as the compiler plugin and
have tried to use similar code to no avail. My code looks like:
/**
* Maven Project
*
* @parameter expression="${project}"
* @required
* @readonly
*/
private MavenProject project;
[...}
final Iterator iterator =
this.getProject().getArtifacts().iterator();
if ( iterator.hasNext() )
{
while ( iterator.hasNext() )
{
Artifact artifact = (Artifact) iterator.next();
final String fileName =artifact.getFile().getAbsolutePath();
this.getLog().info( " Adding to AuxClasspath " + fileName );
findBugsProject.addAuxClasspathEntry( fileName );
}
}
else
{
this.getLog().info( " Nothing to add to AuxClasspath " );
}
[...}
/**
* Returns the maven project.
*
* @return the maven project
* @see org.apache.maven.reporting .AbstractMavenReport#getProject()
*/
protected MavenProject getProject()
{
return this.project;
}
Does anyone have any insight or a reference to more documentation?
--
Regards,
Garvin LeClaire
[EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe from this list please visit:
http://xircles.codehaus.org/manage_email