Skip to content

Workflow file for this run

name: Publish package to the Maven Central Repository
on:
release:
types: [released]
jobs:
publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Maven Central Repository
uses: actions/setup-java@v3
with:
java-version: '17'
distribution: 'adopt'
server-id: ossrh
server-username: OSSRH_USERNAME
server-password: OSSRH_TOKEN
gpg-private-key: ${{secrets.GPG_PRIVATE_KEY}}
gpg-passphrase: GPG_PASSPHRASE
- name: Publish package
run: mvn --batch-mode -Prelease deploy
env:
GPG_PASSPHRASE: ${{secrets.GPG_PASSPHRASE}}
OSSRH_USERNAME: ${{secrets.OSSRH_USERNAME}}
OSSRH_TOKEN: ${{secrets.OSSRH_TOKEN}}