Create GitHub APK Release #3
This file contains hidden or 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: Create GitHub APK Release | |
| on: workflow_dispatch | |
| env: | |
| GRADLE_OPTS: -Dorg.gradle.jvmargs="-Xmx3072m -XX:MaxMetaspaceSize=1g -Xms512m -XX:+HeapDumpOnOutOfMemoryError" | |
| SIGNING_KEYSTORE: ${{ secrets.SIGNING_KEYSTORE }} | |
| SIGNING_PROPERTIES: ${{ secrets.SIGNING_PROPERTIES }} | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup JDK | |
| uses: actions/setup-java@v4 | |
| with: | |
| java-version: 17 | |
| distribution: temurin | |
| - name: Setup Signing | |
| run: chmod +x .github/signing_setup.sh && .github/signing_setup.sh | |
| - name: Build release APK | |
| run: ./gradlew assembleRelease | |
| - name: Extract version from gradle.properties | |
| id: version | |
| run: echo "VERSION=$(grep -Po '^version=\K.*' gradle.properties)" >> $GITHUB_OUTPUT | |
| - name: Create Github Release | |
| uses: softprops/action-gh-release@v2 | |
| with: | |
| tag_name: ${{ steps.version.outputs.VERSION }} | |
| files: app/build/outputs/apk/release/${{ steps.version.outputs.VERSION }}.apk |