Merge pull request #98 from solrudev/develop #13
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: github-release | |
on: | |
push: | |
tags: | |
- "[0-9]+.[0-9]+.[0-9]+*" | |
env: | |
GRADLE_ENCRYPTION_KEY: ${{ secrets.GRADLE_ENCRYPTION_KEY }} | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
name: Build Ackpine | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
persist-credentials: false | |
- name: Copy gradle.properties | |
run: | | |
mkdir -p ~/.gradle | |
cp .github/ci-gradle.properties ~/.gradle/gradle.properties | |
- name: Validate Gradle wrapper | |
uses: gradle/actions/wrapper-validation@v3 | |
- name: Set up JDK | |
uses: actions/setup-java@v4 | |
with: | |
distribution: adopt | |
java-version: 17 | |
cache: gradle | |
- name: Validate binary compatibility | |
run: | | |
./gradlew apiCheck || { exit_code=$?; printf "*** This PR changes Ackpine's public API. If this is intentional, run './gradlew apiDump' and commit the new API dumps. ***"; exit $exit_code; } | |
- name: Build | |
run: | | |
./gradlew :buildAckpine --stacktrace | |
release-samples: | |
name: Release samples | |
runs-on: ubuntu-latest | |
needs: [ build ] | |
permissions: | |
contents: write | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
persist-credentials: false | |
- name: Copy gradle.properties | |
run: | | |
mkdir -p ~/.gradle | |
cp .github/ci-gradle.properties ~/.gradle/gradle.properties | |
- name: Set up JDK | |
uses: actions/setup-java@v4 | |
with: | |
distribution: adopt | |
java-version: 17 | |
cache: gradle | |
- name: Decode key store | |
run: | | |
echo $APP_SIGNING_KEY_STORE > encoded-keystore.txt | |
base64 -d encoded-keystore.txt > $APP_SIGNING_KEY_STORE_PATH | |
env: | |
APP_SIGNING_KEY_STORE: ${{ secrets.APP_SIGNING_KEY_STORE }} | |
APP_SIGNING_KEY_STORE_PATH: ${{ secrets.APP_SIGNING_KEY_STORE_PATH }} | |
- name: Build samples | |
run: | | |
./gradlew :buildSamples --stacktrace | |
env: | |
APP_SIGNING_KEY_ALIAS: ${{ secrets.APP_SIGNING_KEY_ALIAS }} | |
APP_SIGNING_KEY_PASSWORD: ${{ secrets.APP_SIGNING_KEY_PASSWORD }} | |
APP_SIGNING_KEY_STORE_PASSWORD: ${{ secrets.APP_SIGNING_KEY_STORE_PASSWORD }} | |
APP_SIGNING_KEY_STORE_PATH: ${{ secrets.APP_SIGNING_KEY_STORE_PATH }} | |
- name: Extract release changelog | |
run: | | |
./gradlew :releaseChangelog | |
- name: Create GitHub release | |
uses: softprops/action-gh-release@v2 | |
with: | |
body_path: changelog.txt | |
files: | | |
release/* |