Skip to content

Use setup-gradle GitHub action #236

Use setup-gradle GitHub action

Use setup-gradle GitHub action #236

Workflow file for this run

name: CI
on:
pull_request:
jobs:
build:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '11'
- uses: gradle/actions/setup-gradle@v3
- run: ./gradlew assemble
- run: ./gradlew check
- run: |
set -o xtrace
if [ ! -z "${{ secrets.SIGNING_KEY }}" ]; then
./gradlew \
-PVERSION_NAME="unspecified" \
-PsigningInMemoryKey="${{ secrets.SIGNING_KEY }}" \
-PsigningInMemoryKeyPassword="${{ secrets.SIGNING_PASSWORD }}" \
publishToMavenLocal
else
./gradlew \
-PVERSION_NAME="unspecified-SNAPSHOT" \
publishToMavenLocal
fi
if: ${{ github.repository_owner == 'JuulLabs' }}