File tree Expand file tree Collapse file tree 1 file changed +30
-0
lines changed Expand file tree Collapse file tree 1 file changed +30
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : Publish package to the Maven Central Repository
2
+
3
+ on :
4
+ push :
5
+ tags : [ "*" ]
6
+
7
+ jobs :
8
+ publish :
9
+ runs-on : ubuntu-latest
10
+ steps :
11
+ - uses : actions/checkout@v2
12
+ - name : Set up Maven Central Repository
13
+ uses : actions/setup-java@v2
14
+ with :
15
+ java-version : ' 8'
16
+ distribution : ' adopt'
17
+ server-id : ossrh
18
+ server-username : MAVEN_USERNAME
19
+ server-password : MAVEN_PASSWORD
20
+ - id : install-secret-key
21
+ name : Install gpg secret key
22
+ run : |
23
+ cat <(echo -e "${{ secrets.OSSRH_GPG_SECRET_KEY }}") | gpg --batch --import
24
+ gpg --list-secret-keys --keyid-format LONG
25
+ - name : Publish package
26
+ env :
27
+ MAVEN_USERNAME : ${{ secrets.OSSRH_USERNAME }}
28
+ MAVEN_PASSWORD : ${{ secrets.OSSRH_TOKEN }}
29
+ run : mvn --batch-mode -Dgpg.passphrase=${{ secrets.OSSRH_GPG_SECRET_KEY_PASSWORD }} clean deploy
30
+
You can’t perform that action at this time.
0 commit comments