Skip to content

Use Java 21

Use Java 21 #98

Workflow file for this run

name: Ubuntu
on: [push, pull_request]
jobs:
build:
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Checkout submodules
run: git submodule update --init --recursive
- name: Download dependencies
run: |
LIBS_DIR="Snapcast/libs/"
wget https://github.com/badaix/snapcast-deps/releases/download/v0.27.0/boost-1.81.0.aar -P $LIBS_DIR
wget https://github.com/badaix/snapcast-deps/releases/download/v0.27.0/flac-1.4.2.aar -P $LIBS_DIR
wget https://github.com/badaix/snapcast-deps/releases/download/v0.27.0/oboe-1.7.0.aar -P $LIBS_DIR
wget https://github.com/badaix/snapcast-deps/releases/download/v0.27.0/ogg-1.3.5.aar -P $LIBS_DIR
wget https://github.com/badaix/snapcast-deps/releases/download/v0.27.0/opus-1.1.2.aar -P $LIBS_DIR
wget https://github.com/badaix/snapcast-deps/releases/download/v0.27.0/soxr-0.1.3.aar -P $LIBS_DIR
wget https://github.com/badaix/snapcast-deps/releases/download/v0.27.0/tremor-1.0.0.aar -P $LIBS_DIR
wget https://github.com/badaix/snapcast-deps/releases/download/v0.27.0/vorbis-1.3.7.aar -P $LIBS_DIR
- name: Build the app
run: JAVA_HOME=$JAVA_HOME_21_X64 ./gradlew build
- name: rename apk
run: mv /home/runner/work/snapdroid/snapdroid/Snapcast/build/outputs/apk/release/Snapcast-release-unsigned.apk /home/runner/work/snapdroid/snapdroid/Snapcast/build/outputs/apk/release/Snapcast.apk
- uses: r0adkll/sign-android-release@v1
if: github.event_name == 'push'
name: Sign app APK
# ID used to access action output
id: sign_app
with:
releaseDirectory: /home/runner/work/snapdroid/snapdroid/Snapcast/build/outputs/apk/release
signingKeyBase64: ${{ secrets.SIGNING_KEY }}
alias: ${{ secrets.ALIAS }}
keyStorePassword: ${{ secrets.KEY_STORE_PASSWORD }}
keyPassword: ${{ secrets.KEY_PASSWORD }}
env:
# override default build-tools version (29.0.3) -- optional
BUILD_TOOLS_VERSION: "34.0.0"
- name: Archive artifacts
if: github.event_name == 'push'
uses: actions/upload-artifact@v3
with:
name: develop_snapshot-${{github.sha}}
path: ${{steps.sign_app.outputs.signedReleaseFile}}