Skip to content

log version

log version #12

Workflow file for this run

name: Publish to Maven
on:
push:
branches:
- master
- maven
env:
SONATYPE_TOKEN: ${{ secrets.SONATYPE_TOKEN }}
SIGNING_KEYID: ${{ secrets.SIGNING_KEYID }}
SIGNING_PASSWORD: ${{ secrets.SIGNING_PASSWORD }}
SIGNING_SECRET_KEY_RING_CONTENT: ${{ secrets.SIGNING_SECRET_KEY_RING_CONTENT }}
SIGNING_SECRET_PASSPHRASE: ${{ secrets.SIGNING_SECRET_PASSPHRASE }}
jobs:
publish:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Set up JDK 17
uses: actions/setup-java@v2
with:
distribution: 'adopt'
java-version: '17'
- name: Prepare environment
run: |
echo "$SIGNING_SECRET_KEY_RING_CONTENT" | base64 -d > publish_key.gpg
gpg --version
gpg --batch --yes --decrypt --passphrase="SIGNING_SECRET_PASSPHRASE" --output secret.gpg publish_key.gpg
- name: Grant execute permission for gradlew
run: chmod +x ./gradlew
- name: Publish with Gradle
run: ./gradlew publish -Psigning.secretKeyRingFile=../secret.gpg -Psigning.keyId=$SIGNING_KEYID -Psigning.password=$SIGNING_PASSWORD -Ptoken="$SONATYPE_TOKEN"