Skip to content
This repository was archived by the owner on Mar 12, 2026. It is now read-only.

Commit 5a87153

Browse files
committed
add release CI (#66)
1 parent 7e80e0a commit 5a87153

1 file changed

Lines changed: 27 additions & 0 deletions

File tree

.github/workflows/release.yml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: Publish package to the Maven Central Repository
2+
3+
on:
4+
workflow_dispatch:
5+
jobs:
6+
publish:
7+
runs-on: ubuntu-latest
8+
steps:
9+
- uses: actions/checkout@v2
10+
- name: Set up Maven Central Repository
11+
uses: actions/setup-java@v3
12+
with:
13+
java-version: '8'
14+
distribution: 'adopt'
15+
server-id: ossrh
16+
server-username: MAVEN_USERNAME
17+
server-password: MAVEN_PASSWORD
18+
- id: install-secret-key
19+
name: Install gpg secret key
20+
run: |
21+
cat <(echo -e "${{ secrets.OSSRH_GPG_SECRET_KEY }}") | gpg --batch --import
22+
gpg --list-secret-keys --keyid-format LONG
23+
- name: Publish package
24+
env:
25+
MAVEN_USERNAME: ${{ secrets.OSSRH_USERNAME }}
26+
MAVEN_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}
27+
run: mvn --batch-mode -Dgpg.passphrase=${{ secrets.OSSRH_GPG_SECRET_KEY_PASSWORD }} clean deploy

0 commit comments

Comments
 (0)