From be1e840ffe9f76e050f74f095e15bee58fdb1200 Mon Sep 17 00:00:00 2001 From: Harsh Shandilya Date: Mon, 7 Dec 2020 13:13:45 +0530 Subject: github: rename release.yml to deploy_github_releases.yml Signed-off-by: Harsh Shandilya --- .github/workflows/deploy_github_releases.yml | 127 +++++++++++++++++++++++++++ .github/workflows/release.yml | 127 --------------------------- 2 files changed, 127 insertions(+), 127 deletions(-) create mode 100644 .github/workflows/deploy_github_releases.yml delete mode 100644 .github/workflows/release.yml (limited to '.github') diff --git a/.github/workflows/deploy_github_releases.yml b/.github/workflows/deploy_github_releases.yml new file mode 100644 index 00000000..d9e51427 --- /dev/null +++ b/.github/workflows/deploy_github_releases.yml @@ -0,0 +1,127 @@ +name: Publish APS binaries to GitHub Releases +on: + push: + tags: + - 'v[0-9]+.[0-9]+.[0-9]+' + +jobs: + build: + name: Build release binaries + runs-on: ubuntu-latest + steps: + - name: Checkout repository + uses: actions/checkout@c952173edf28a2bd22e1a4926590c1ac39630461 + + - name: Decrypt secrets + run: scripts/signing-setup.sh "$ENCRYPT_KEY" + env: + ENCRYPT_KEY: ${{ secrets.ENCRYPT_KEY }} + + - name: Copy CI gradle.properties + run: mkdir -p ~/.gradle ; cp .github/ci-gradle.properties ~/.gradle/gradle.properties + + - name: Build release binaries + uses: burrunan/gradle-cache-action@03c71a8ba93d670980695505f48f49daf43704a6 + with: + arguments: :app:assembleFreeRelease :app:assembleNonFreeRelease :app:bundleNonFreeRelease + + - name: Upload non-free release APK + uses: actions/upload-artifact@27bce4eee761b5bc643f46a8dfb41b430c8d05f6 + with: + name: APS Non-Free Release APK + path: app/build/outputs/apk/nonFree/release/app-nonFree-release.apk + + - name: Upload non-free release Bundle + uses: actions/upload-artifact@27bce4eee761b5bc643f46a8dfb41b430c8d05f6 + with: + name: APS Non-Free Release Bundle + path: app/build/outputs/bundle/nonFreeRelease/app-nonFree-release.aab + + - name: Upload free release APK + uses: actions/upload-artifact@27bce4eee761b5bc643f46a8dfb41b430c8d05f6 + with: + name: APS Free Release APK + path: app/build/outputs/apk/free/release/app-free-release.apk + + - name: Clean secrets + if: always() + run: scripts/signing-cleanup.sh + + create_github_release: + name: Create GitHub Release + runs-on: ubuntu-latest + needs: build + steps: + - name: Checkout + uses: actions/checkout@c952173edf28a2bd22e1a4926590c1ac39630461 + + - name: Get Non-Free Release APK + uses: actions/download-artifact@f60857ee283b759efd0a9bf31b1b24a2d9c7e5cd + with: + name: APS Non-Free Release APK + path: artifacts/nonFree + + - name: Get Non-Free Bundle + uses: actions/download-artifact@f60857ee283b759efd0a9bf31b1b24a2d9c7e5cd + with: + name: APS Non-Free Release Bundle + path: artifacts/nonFree + + - name: Get Free Release APK + uses: actions/download-artifact@f60857ee283b759efd0a9bf31b1b24a2d9c7e5cd + with: + name: APS Free Release APK + path: artifacts/free + + - name: Get Changelog Entry + id: changelog_reader + uses: mindsers/changelog-reader-action@30552f0e948002519ff6b36ffbf889ef4da47246 + with: + version: ${{ github.ref }} + path: ./CHANGELOG.md + + - name: Create Release + id: create_release + uses: actions/create-release@c38d3a140cc22e67e265c5d5b6b4888d1f02533f + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + tag_name: ${{ github.ref }} + release_name: ${{ github.ref }} + body: ${{ steps.changelog_reader.outputs.log_entry }} + draft: true + prerelease: false + + - name: Get the version + id: get_version + run: echo ::set-output name=VERSION::${GITHUB_REF#refs/tags/} + + - name: Upload Non-Free Release Apk + uses: actions/upload-release-asset@e9f0662bdf9868f4aac644f0eedc2b56567fdba8 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} + asset_path: ./artifacts/nonFree/app-nonFree-release.apk + asset_name: APS-nonFree_${{ steps.get_version.outputs.VERSION }}.apk + asset_content_type: application/vnd.android.package-archive + + - name: Upload Non-Free Release Bundle + uses: actions/upload-release-asset@e9f0662bdf9868f4aac644f0eedc2b56567fdba8 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} + asset_path: ./artifacts/nonFree/app-nonFree-release.aab + asset_name: APS-nonFree_${{ steps.get_version.outputs.VERSION }}.aab + asset_content_type: application/octet-stream + + - name: Upload Free Release Apk + uses: actions/upload-release-asset@e9f0662bdf9868f4aac644f0eedc2b56567fdba8 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} + asset_path: ./artifacts/free/app-free-release.apk + asset_name: APS-free_${{ steps.get_version.outputs.VERSION }}.apk + asset_content_type: application/vnd.android.package-archive diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml deleted file mode 100644 index 68065b7f..00000000 --- a/.github/workflows/release.yml +++ /dev/null @@ -1,127 +0,0 @@ -name: Release -on: - push: - tags: - - 'v[0-9]+.[0-9]+.[0-9]+' - -jobs: - build: - name: Build release binaries - runs-on: ubuntu-latest - steps: - - name: Checkout repository - uses: actions/checkout@c952173edf28a2bd22e1a4926590c1ac39630461 - - - name: Decrypt secrets - run: scripts/signing-setup.sh "$ENCRYPT_KEY" - env: - ENCRYPT_KEY: ${{ secrets.ENCRYPT_KEY }} - - - name: Copy CI gradle.properties - run: mkdir -p ~/.gradle ; cp .github/ci-gradle.properties ~/.gradle/gradle.properties - - - name: Build release binaries - uses: burrunan/gradle-cache-action@03c71a8ba93d670980695505f48f49daf43704a6 - with: - arguments: :app:assembleFreeRelease :app:assembleNonFreeRelease :app:bundleNonFreeRelease - - - name: Upload non-free release APK - uses: actions/upload-artifact@27bce4eee761b5bc643f46a8dfb41b430c8d05f6 - with: - name: APS Non-Free Release APK - path: app/build/outputs/apk/nonFree/release/app-nonFree-release.apk - - - name: Upload non-free release Bundle - uses: actions/upload-artifact@27bce4eee761b5bc643f46a8dfb41b430c8d05f6 - with: - name: APS Non-Free Release Bundle - path: app/build/outputs/bundle/nonFreeRelease/app-nonFree-release.aab - - - name: Upload free release APK - uses: actions/upload-artifact@27bce4eee761b5bc643f46a8dfb41b430c8d05f6 - with: - name: APS Free Release APK - path: app/build/outputs/apk/free/release/app-free-release.apk - - - name: Clean secrets - if: always() - run: scripts/signing-cleanup.sh - - create_github_release: - name: Create GitHub Release - runs-on: ubuntu-latest - needs: build - steps: - - name: Checkout - uses: actions/checkout@c952173edf28a2bd22e1a4926590c1ac39630461 - - - name: Get Non-Free Release APK - uses: actions/download-artifact@f60857ee283b759efd0a9bf31b1b24a2d9c7e5cd - with: - name: APS Non-Free Release APK - path: artifacts/nonFree - - - name: Get Non-Free Bundle - uses: actions/download-artifact@f60857ee283b759efd0a9bf31b1b24a2d9c7e5cd - with: - name: APS Non-Free Release Bundle - path: artifacts/nonFree - - - name: Get Free Release APK - uses: actions/download-artifact@f60857ee283b759efd0a9bf31b1b24a2d9c7e5cd - with: - name: APS Free Release APK - path: artifacts/free - - - name: Get Changelog Entry - id: changelog_reader - uses: mindsers/changelog-reader-action@30552f0e948002519ff6b36ffbf889ef4da47246 - with: - version: ${{ github.ref }} - path: ./CHANGELOG.md - - - name: Create Release - id: create_release - uses: actions/create-release@c38d3a140cc22e67e265c5d5b6b4888d1f02533f - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - tag_name: ${{ github.ref }} - release_name: ${{ github.ref }} - body: ${{ steps.changelog_reader.outputs.log_entry }} - draft: true - prerelease: false - - - name: Get the version - id: get_version - run: echo ::set-output name=VERSION::${GITHUB_REF#refs/tags/} - - - name: Upload Non-Free Release Apk - uses: actions/upload-release-asset@e9f0662bdf9868f4aac644f0eedc2b56567fdba8 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - upload_url: ${{ steps.create_release.outputs.upload_url }} - asset_path: ./artifacts/nonFree/app-nonFree-release.apk - asset_name: APS-nonFree_${{ steps.get_version.outputs.VERSION }}.apk - asset_content_type: application/vnd.android.package-archive - - - name: Upload Non-Free Release Bundle - uses: actions/upload-release-asset@e9f0662bdf9868f4aac644f0eedc2b56567fdba8 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - upload_url: ${{ steps.create_release.outputs.upload_url }} - asset_path: ./artifacts/nonFree/app-nonFree-release.aab - asset_name: APS-nonFree_${{ steps.get_version.outputs.VERSION }}.aab - asset_content_type: application/octet-stream - - - name: Upload Free Release Apk - uses: actions/upload-release-asset@e9f0662bdf9868f4aac644f0eedc2b56567fdba8 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - upload_url: ${{ steps.create_release.outputs.upload_url }} - asset_path: ./artifacts/free/app-free-release.apk - asset_name: APS-free_${{ steps.get_version.outputs.VERSION }}.apk - asset_content_type: application/vnd.android.package-archive -- cgit v1.2.3