It turns out this little properties trick doesn't work when the
version is a shapshot. When the assembly is built, none of the
maven2 snapshot artifacts will have 'SNAPSHOT' in their name.
They'll be "xbean-finder-2.8-20061102.070155-2.jar", etc. Except
your own jars, those will still have "SNAPSHOT" in their name for
some strange reason.
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<configuration>
<archive>
<manifest>
<mainClass>org.apache.openejb.cli.Main</mainClass>
<!--<addClasspath>true</addClasspath>-->
</manifest>
<manifestEntries>
<Class-Path>openejb-loader-${pom.version}.jar
xbean-finder-$
{removePropertyFromCorePomXbeanVersion}.jar</Class-Path>
</manifestEntries>
</archive>
</configuration>
</plugin>
Anyway, going to fix this by making the Main class not require xbean-
finder. Simply going to make a new main essentially that loads
finder then calls the existing Main. Then we don't have to mess with
this stuff again.
And just in case Brett reads this, here's my suggestion for the jar
plugin: you should use syntax similar to the assembly plugin to point
to deps. Meaning this:
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<configuration>
<archive>
<manifest>
<mainClass>org.apache.openejb.cli.Main</mainClass>
</manifest>
<manifestEntries>
<Class-Path>
<include>org.apache.openejb:openejb-loader</include>
<include>org.apache.xbean:xbean-finder</include>
</Class-Path>
</manifestEntries>
</archive>
</configuration>
</plugin>
-David