I want to use the Maven release plugin to release my Eclipse plugins, but in the release:prepare step, I have to skip updating the version number of some of the plugins. This is because they are a modified version of a plugin other 3rd party plugins depend on.
What I have tried is explicitely seeting the versions to the existing ones:
mvn release:prepare -DreleaseVersion=1.1.99 -Dproject.rel.org.eclipse.linuxtools.docker.core:org.eclipse.linuxtools.docker.core=4.1.0 -Dproject.dev.org.eclipse.linuxtools.docker.core:org.eclipse.linuxtools.docker.core=4.1.0-SNAPSHOT
This did not work for me, the release plugin still tried to change the versions.
Next I tried to separate the plugins into profiles, and only call release:prepare for the ones I wanted changed:
pom.xml
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<artifactId>com.conti.daisy.bundles</artifactId>
<packaging>pom</packaging>
<parent>
<groupId>com.conti.daisy</groupId>
<artifactId>com.conti.daisy.build.parent</artifactId>
<version>1.0.0-SNAPSHOT</version>
<relativePath>./com.conti.daisy.build.parent</relativePath>
</parent>
<profiles>
<profile>
<id>daisy</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<modules>
...
</modules>
</profile>
<profile>
<id>linuxtools</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<modules>
<module>org.eclipse.linuxtools.docker.core</module>
</modules>
</profile>
command
mvn install -P !daisy # make sure I have the linuxtools plugins in the local repo
mvn release:prepare -P !linuxtools -DreleaseVersion=1.1.99
This has the drawback that the references to the parent pom are not updated in the skipped plugins, and that again makes the build break for me.
How is this properly handled?
developmentVersion
? – J Fabian MeierreleaseVersion
I should havedevelopmentVersion
. In the first case I actually did explicitely set the development version for the module in question, but maybe I did something wrong, it didn't work as expected:-Dproject.dev.org.eclipse.linuxtools.docker.core:org.eclipse.linuxtools.docker.core=4.1.0-SNAPSHOT
– kutschkem