|
80 | 80 | <log.version>1.3.2</log.version> |
81 | 81 | <metatype.version>1.2.4</metatype.version> |
82 | 82 | <servicemix.junit.version>4.13.2_1</servicemix.junit.version> |
| 83 | + <!-- set to false by the performRelease profile, see tag-bundles below --> |
| 84 | + <dependencymanager.tag.skip>true</dependencymanager.tag.skip> |
83 | 85 | </properties> |
84 | 86 |
|
85 | 87 | <dependencyManagement> |
|
190 | 192 | </execution> |
191 | 193 | </executions> |
192 | 194 | </plugin> |
| 195 | + <!-- |
| 196 | + The release plugin makes one tag for the whole reactor (dependencymanager-parent-x.y.z). On top |
| 197 | + of that every released bundle gets its own tag, <artifactId>-<version>, like the earlier releases. |
| 198 | + Only the bundles that list this plugin in their build are tagged, and only while performing a |
| 199 | + release: release:perform builds the tag that was just made, so HEAD of its checkout is the release. |
| 200 | + --> |
| 201 | + <plugin> |
| 202 | + <groupId>org.codehaus.mojo</groupId> |
| 203 | + <artifactId>exec-maven-plugin</artifactId> |
| 204 | + <version>3.5.0</version> |
| 205 | + <configuration> |
| 206 | + <skip>${dependencymanager.tag.skip}</skip> |
| 207 | + <executable>git</executable> |
| 208 | + </configuration> |
| 209 | + <executions> |
| 210 | + <execution> |
| 211 | + <id>tag-bundle</id> |
| 212 | + <phase>deploy</phase> |
| 213 | + <goals> |
| 214 | + <goal>exec</goal> |
| 215 | + </goals> |
| 216 | + <configuration> |
| 217 | + <arguments> |
| 218 | + <argument>tag</argument> |
| 219 | + <argument>${project.artifactId}-${project.version}</argument> |
| 220 | + </arguments> |
| 221 | + </configuration> |
| 222 | + </execution> |
| 223 | + <execution> |
| 224 | + <id>push-bundle-tag</id> |
| 225 | + <phase>deploy</phase> |
| 226 | + <goals> |
| 227 | + <goal>exec</goal> |
| 228 | + </goals> |
| 229 | + <configuration> |
| 230 | + <arguments> |
| 231 | + <argument>push</argument> |
| 232 | + <argument>origin</argument> |
| 233 | + <argument>refs/tags/${project.artifactId}-${project.version}</argument> |
| 234 | + </arguments> |
| 235 | + </configuration> |
| 236 | + </execution> |
| 237 | + </executions> |
| 238 | + </plugin> |
193 | 239 | </plugins> |
194 | 240 | </pluginManagement> |
195 | 241 | </build> |
| 242 | + |
| 243 | + <profiles> |
| 244 | + <profile> |
| 245 | + <!-- release:perform sets performRelease --> |
| 246 | + <id>tag-bundles</id> |
| 247 | + <activation> |
| 248 | + <property> |
| 249 | + <name>performRelease</name> |
| 250 | + <value>true</value> |
| 251 | + </property> |
| 252 | + </activation> |
| 253 | + <properties> |
| 254 | + <dependencymanager.tag.skip>false</dependencymanager.tag.skip> |
| 255 | + </properties> |
| 256 | + </profile> |
| 257 | + </profiles> |
196 | 258 | </project> |
0 commit comments