File tree Expand file tree Collapse file tree 2 files changed +20
-0
lines changed Expand file tree Collapse file tree 2 files changed +20
-0
lines changed Original file line number Diff line number Diff line change 2323 server-id : ossrh
2424 server-username : MAVEN_USERNAME
2525 server-password : MAVEN_PASSWORD
26+ gpg-passphrase : MAVEN_GPG_PASSPHRASE
2627 - name : Deploy pre-release version to the Maven Central Repository
2728 run : |
2829 pre_release_version=${{ github.event.release.tag_name }}
3334 env :
3435 MAVEN_USERNAME : ${{ secrets.OSSRH_USERNAME }}
3536 MAVEN_PASSWORD : ${{ secrets.OSSRH_TOKEN }}
37+ MAVEN_GPG_PASSPHRASE : ${{ secrets.MAVEN_GPG_PASSPHRASE }}
3638 - name : Set up Java for publishing to GitHub Packages
3739 uses : actions/setup-java@v1
3840 with :
Original file line number Diff line number Diff line change 275275 </execution >
276276 </executions >
277277 </plugin >
278+ <plugin >
279+ <artifactId >maven-gpg-plugin</artifactId >
280+ <version >${maven-gpg-plugin.version} </version >
281+ <executions >
282+ <execution >
283+ <id >sign-artifacts</id >
284+ <goals >
285+ <goal >sign</goal >
286+ </goals >
287+ </execution >
288+ </executions >
289+ </plugin >
278290 <!-- Docker -->
279291 <plugin >
280292 <groupId >com.spotify</groupId >
415427 </profile >
416428 <profile >
417429 <id >deploy2Maven</id >
430+ <properties >
431+ <gpg .passphrase>${env.MAVEN_GPG_PASSPHRASE} </gpg .passphrase>
432+ </properties >
418433 <distributionManagement >
419434 <repository >
420435 <id >ossrh</id >
428443 <groupId >org.sonatype.plugins</groupId >
429444 <artifactId >nexus-staging-maven-plugin</artifactId >
430445 </plugin >
446+ <plugin >
447+ <artifactId >maven-gpg-plugin</artifactId >
448+ </plugin >
431449 </plugins >
432450 </build >
433451 </profile >
You can’t perform that action at this time.
0 commit comments