Build #54
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: Build | |
| on: | |
| schedule: | |
| - cron: '0 0 * * 0' | |
| workflow_dispatch: | |
| branches: | |
| - '**' | |
| jobs: | |
| build: | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@main | |
| - name: Set up JDK | |
| uses: actions/setup-java@main | |
| with: | |
| java-version: 25 | |
| distribution: temurin | |
| - name: Set-up NDK | |
| run: | | |
| yes | "${ANDROID_HOME}/cmdline-tools/latest/bin/sdkmanager" --licenses | |
| ./gradlew --warning-mode 'all' --no-daemon clean | |
| - name: Install android-gcc-cross | |
| run: | | |
| declare -r PINO_TAG="$(jq --raw-output '.tag_name' <<< "$(curl --connect-timeout '10' --retry '15' --retry-all-errors --fail --silent --url 'https://api.github.com/repos/AmanoTeam/android-gcc-cross/releases/latest')")" | |
| declare -r PINO_TARBALL='/tmp/toolchain.tar.xz' | |
| declare -r PINO_URL="https://github.com/AmanoTeam/android-gcc-cross/releases/download/${PINO_TAG}/x86_64-unknown-linux-gnu.tar.xz" | |
| curl --connect-timeout '10' --retry '15' --retry-all-errors --fail --silent --location --url "${PINO_URL}" --output "${PINO_TARBALL}" | |
| tar --directory="$(dirname "${PINO_TARBALL}")" --extract --file="${PINO_TARBALL}" | |
| echo '/tmp/android-gcc-cross/bin' >> "${GITHUB_PATH}" | |
| echo 'PINO_OPT_LEVEL=fast' >> "${GITHUB_ENV}" | |
| - name: Patch the NDK | |
| run: | | |
| ndk-patch | |
| - name: Run update.sh | |
| run: | | |
| bash tools/update.sh | |
| - name: Build Android project | |
| env: | |
| PINO_LTO: full | |
| run: | | |
| ./gradlew --warning-mode 'all' --no-daemon 'assembleRelease' | |
| - name: Upload artifact | |
| uses: actions/upload-artifact@main | |
| with: | |
| path: ./app/build/outputs/apk/release/app-release-unsigned.apk | |
| - name: Create release | |
| uses: softprops/action-gh-release@master | |
| with: | |
| tag_name: '${{ env.APP_VERSION }}' | |
| name: 'Just Delete Me v${{ env.APP_VERSION }}' | |
| files: ./app/build/outputs/apk/release/app-release-unsigned.apk | |
| draft: false | |
| prerelease: false | |
| fail_on_unmatched_files: true | |
| body: "* Update entries" | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |