-
Notifications
You must be signed in to change notification settings - Fork 107
32 lines (27 loc) · 926 Bytes
/
release.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
name: Release
on:
workflow_dispatch:
jobs:
release:
name: Release to Maven Central
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Maven Central
uses: actions/setup-java@v2
with:
distribution: 'zulu'
java-version: 11
server-id: ossrh
server-username: OSSRH_USERNAME
server-password: OSSRH_TOKEN
gpg-private-key: ${{ secrets.GPG_PRIVATE_KEY }}
- name: Publish to Maven Central
run: |
git config user.name '${{ github.actor }}'
git config user.email '${{ github.actor }}@users.noreply.github.com'
mvn -B release:prepare release:perform -Dpassword=${{ secrets.GITHUB_TOKEN }}
env:
OSSRH_USERNAME: ${{ secrets.OSSRH_USERNAME }}
OSSRH_TOKEN: ${{ secrets.OSSRH_TOKEN }}
GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }}