name: android # build on c/cpp changes or workflow changes on: push: paths: - 'lib/**.[ch]' - 'lib/**.cpp' - 'src/**.[ch]' - 'src/**.cpp' - 'Android/**' - '.github/workflows/android.yml' pull_request: paths: - 'lib/**.[ch]' - 'lib/**.cpp' - 'src/**.[ch]' - 'src/**.cpp' - 'Android/**' - '.github/workflows/android.yml' jobs: build: runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 - name: Set up JDK 17 uses: actions/setup-java@v3 with: distribution: 'temurin' java-version: '17' - name: Install GNU gettext run: sudo apt install gettext - name: Build with Gradle run: cd Android; ./gradlew assemblerelease - name: Save armeabi artifact uses: actions/upload-artifact@v3 with: name: MultiCraft-armeabi-v7a.apk path: Android/app/build/outputs/apk/release/app-armeabi-v7a-release-unsigned.apk - name: Save arm64 artifact uses: actions/upload-artifact@v3 with: name: MultiCraft-arm64-v8a.apk path: Android/app/build/outputs/apk/release/app-arm64-v8a-release-unsigned.apk