Skip to content

Commit e8f8f93

Browse files
authored
Sonatype deploy: use maven versions plugin (#50) +semver: feature
* Sonatype deploy: use maven versions plugin (to set version correctly in pom before package upload)
1 parent 273e9f5 commit e8f8f93

File tree

2 files changed

+14
-3
lines changed

2 files changed

+14
-3
lines changed

.github/workflows/release-maven-central.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,12 @@ jobs:
5454

5555
- name: Step 6 - Publish package
5656
run: |
57-
mvn -B --no-transfer-progress -Dmaven.test.skip=true -Drevision=${{ steps.gitversion.outputs.semVer }} deploy
57+
mvn -B --no-transfer-progress \
58+
versions:set \
59+
-DnewVersion=${{ steps.gitversion.outputs.semVer }} \
60+
-DgenerateBackupPoms=false \
61+
-DprocessAllModules
62+
mvn -B --no-transfer-progress -Dmaven.test.skip=true deploy
5863
env:
5964
MVN_CENTRAL_USERNAME: ${{ secrets.OSSRH_USERNAME }}
6065
MVN_CENTRAL_PASSWORD: ${{ secrets.OSSRH_TOKEN }}

pom.xml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
<groupId>com.github.aquality-automation</groupId>
88
<artifactId>aquality-appium-mobile</artifactId>
9-
<version>${revision}</version>
9+
<version>5.4.1</version>
1010

1111
<packaging>jar</packaging>
1212
<name>Aquality Appium Mobile</name>
@@ -16,7 +16,6 @@
1616
<properties>
1717
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
1818
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
19-
<revision>5.3.1</revision>
2019
</properties>
2120

2221
<scm>
@@ -61,6 +60,7 @@
6160
<plugin>
6261
<groupId>org.apache.maven.plugins</groupId>
6362
<artifactId>maven-compiler-plugin</artifactId>
63+
<version>3.14.0</version>
6464
<configuration>
6565
<source>11</source>
6666
<target>11</target>
@@ -97,6 +97,7 @@
9797
<plugin>
9898
<groupId>org.apache.maven.plugins</groupId>
9999
<artifactId>maven-assembly-plugin</artifactId>
100+
<version>3.7.1</version>
100101
<executions>
101102
<execution>
102103
<goals>
@@ -171,6 +172,11 @@
171172
<waitUntil>published</waitUntil>
172173
</configuration>
173174
</plugin>
175+
<plugin>
176+
<groupId>org.codehaus.mojo</groupId>
177+
<artifactId>versions-maven-plugin</artifactId>
178+
<version>2.18.0</version>
179+
</plugin>
174180
</plugins>
175181
</build>
176182

0 commit comments

Comments
 (0)