File tree Expand file tree Collapse file tree 1 file changed +7
-15
lines changed
Expand file tree Collapse file tree 1 file changed +7
-15
lines changed Original file line number Diff line number Diff line change 11name : Publish package to the Maven Central Repository
22on :
3- release :
4- types : [created]
3+ release :
4+ types : [created]
55jobs :
66 publish :
77 runs-on : ubuntu-latest
@@ -12,22 +12,14 @@ jobs:
1212 with :
1313 java-version : " 17"
1414 distribution : " temurin"
15- server-id : ossrh
15+ server-id : central
1616 server-username : MAVEN_USERNAME
1717 server-password : MAVEN_PASSWORD
18- - name : Install gpg secret key
19- run : |
20- # Install gpg secret key
21- echo "${{ secrets.OSSRH_GPG_SECRET_KEY }}" | base64 --decode | gpg --batch --import
22- # Verify that the key ID is shown in the logs
23- gpg --list-secret-keys --keyid-format LONG | grep "${{ secrets.OSSRH_GPG_SECRET_KEY_ID }}"
18+ gpg-private-key : ${{ secrets.GPG_PRIVATE_KEY }}
19+ gpg-passphrase : MAVEN_GPG_PASSPHRASE
2420 - name : Publish to Central Repository
2521 env :
2622 MAVEN_USERNAME : ${{ secrets.OSSRH_USERNAME }}
2723 MAVEN_PASSWORD : ${{ secrets.OSSRH_TOKEN }}
28- run : |
29- mvn \
30- --no-transfer-progress \
31- --batch-mode \
32- -Dgpg.passphrase=${{ secrets.OSSRH_GPG_SECRET_KEY_PASSWORD }} \
33- clean deploy
24+ MAVEN_GPG_PASSPHRASE : ${{ secrets.OSSRH_GPG_SECRET_KEY_PASSWORD }}
25+ run : mvn --batch-mode deploy
You can’t perform that action at this time.
0 commit comments