v1.3.0 #7
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Publish to Maven Central | |
on: | |
workflow_dispatch: | |
release: | |
types: [created] | |
jobs: | |
publish: | |
name: Publish Release Artifacts | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out the repo | |
uses: actions/checkout@v3 | |
- name: Validate Gradle wrapper | |
uses: gradle/wrapper-validation-action@v1 | |
- name: Set up Java 11 JDK | |
uses: actions/setup-java@v3 | |
with: | |
distribution: 'temurin' | |
java-version: 11 | |
architecture: x64 | |
cache: 'gradle' | |
check-latest: true | |
- name: Change wrapper permissions | |
run: chmod +x ./gradlew | |
- name: Decode GPG Key | |
run: | | |
mkdir -p ~/.gradle/ | |
echo "${{secrets.OSSRH_GPG_SECRET_KEY}}" > ~/.gradle/secring.gpg.b64 | |
base64 -d ~/.gradle/secring.gpg.b64 > ~/.gradle/secring.gpg | |
- name: Publish package | |
run: ./gradlew publish -Psigning.keyId=${{secrets.OSSRH_GPG_SECRET_KEY_ID}} -Psigning.password=${{secrets.OSSRH_GPG_SECRET_KEY_PASSWORD}} -Psigning.secretKeyRingFile=$(echo ~/.gradle/secring.gpg) --warn --stacktrace | |
env: | |
OSSRH_USERNAME: ${{secrets.OSSRH_USERNAME}} | |
OSSRH_PASSWORD: ${{secrets.OSSRH_PASSWORD}} |