Skip to content

Commit a64abd4

Browse files
committed
(ci) upgrade Jenkinsfile to jdk21
1 parent 45625c3 commit a64abd4

File tree

3 files changed

+17
-12
lines changed

3 files changed

+17
-12
lines changed

.github/workflows/maven-publish-ghpkg.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ jobs:
6363
]
6464
6565
- name: Publish to GitHub Packages Apache Maven
66-
run: mvn --batch-mode deploy
66+
run: mvn --batch-mode deploy -Pdeploy-github
6767
env:
6868
MAVEN_PUBLISH_URL: https://maven.pkg.github.com/${{github.repository}}
6969

Jenkinsfile

+3-2
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,11 @@ pipeline {
33
stages {
44
stage('Build') {
55
tools {
6-
jdk "jdk17"
6+
jdk "jdk21"
7+
maven "apache-maven-3.9.9"
78
}
89
steps {
9-
sh 'mvn -DjenkinsBuildNumber=${BUILD_NUMBER} clean package'
10+
sh 'mvn package'
1011
}
1112
}
1213
}

pom.xml

+13-9
Original file line numberDiff line numberDiff line change
@@ -179,13 +179,17 @@
179179
</plugin>
180180
</plugins>
181181
</build>
182-
183-
<distributionManagement>
184-
<repository>
185-
<id>maven-publish</id>
186-
<url>${env.MAVEN_PUBLISH_URL}</url>
187-
<!-- refer to .github/workflows/maven-publish-ghpkg.yml -->
188-
</repository>
189-
</distributionManagement>
190-
182+
183+
<profiles>
184+
<profile>
185+
<id>deploy-github</id>
186+
<distributionManagement>
187+
<repository>
188+
<id>maven-publish</id>
189+
<url>${env.MAVEN_PUBLISH_URL}</url>
190+
<!-- refer to .github/workflows/maven-publish-ghpkg.yml -->
191+
</repository>
192+
</distributionManagement>
193+
</profile>
194+
</profiles>
191195
</project>

0 commit comments

Comments
 (0)