Hi Hubert,
2008/8/15 Hubert Behaghel <[EMAIL PROTECTED]>:
> I am using the APT maven plugin with success up to now but was
> wondering what would be suggested when it comes to taking into account
> sources that are inside jars as project dependencies.
>
> After spending a couple of hours on this, I ended up with patching my
> own version of the plugin and adding this mechanism :
>
> If project has dependencies with the 'sources' classifier, the patched
> plugin will unzip each of them in target/sources-jar/[artifactId] and
> add this path to the additionalSourceRoots var that is already offered
> by the plugin.
>
> I am not sure it is the right way to go : what do you think ?
It seems like a valid feature to request. I'd like to see it
implemented by specifying the dependencies to process in the plugin
configuration, for example:
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>apt-maven-plugin</artifactId>
<configuration>
<sourceDependencies>
<sourceDependency>mygroup:myartifact</sourceDependency>
</sourceDependencies>
</configuration>
<dependencies>
<dependency>
<groupId>mygroup</groupId>
<artifactId>myartifact</artifactId>
<version>1.0</version>
<classifier>sources</classifier>
</dependency>
</dependencies>
</plugin>
We could then perhaps supply jar urls to apt to avoid unzipping them,
if apt supports such a feature. Feel free to raise an issue under the
apt component here for this:
http://jira.codehaus.org/browse/MOJO
Cheers,
Mark
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email