Max Bowsher wrote:
Is it possible to use POM elements to configure the standard
maven-jar-plugin to use a custom version of maven-archiver?
I am attempting to use:
<build>
<plugins>
<plugin>
<artifactId>maven-jar-plugin</artifactId>
<dependencies>
<dependency>
<artifactId>maven-archiver</artifactId>
<groupId>org.apache.maven</groupId>
<version>2.2-maxb-1</version>
<scope>runtime</scope>
</dependency>
</dependencies>
However, this does not work. The version of maven-archiver specified
directly in the jar plugin is used instead:
'mvn -X package' shows:
[DEBUG]
org.apache.maven.plugins:maven-jar-plugin:maven-plugin:2.1:runtime
(selected for runtime)
...
[DEBUG] org.apache.maven:maven-archiver:jar:2.2:runtime (selected
for runtime)
...
[DEBUG] org.apache.maven:maven-archiver:jar:2.2-maxb-1:runtime
(removed - nearer found: 2.2)
Must I make a custom version of the jar plugin too, to convince it to
use a custom maven-archiver?
Thanks in advance for any insight.
Jason Dillon wrote:
Not sure that maven can calculate that 2.2-maxb-1 > 2.2. Try to use a
more standard version... like 2.3-SNAPSHOT, and if you want maxb-1, then
put that in the classifier.
I tried changing the version to 2.3-SNAPSHOT - no change, *exactly* the
same behaviour, just substituting "2.3-SNAPSHOT" for "2.2-maxb-1" in the
output.
Maven's claiming that 2.2 is nearer - not newer.
--
Max Bowsher <[EMAIL PROTECTED]>
http://www.mxtelecom.com
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]