Release v0.20.2 #14
Workflow file for this run
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: Release | |
| on: | |
| push: | |
| tags: | |
| - v* | |
| env: | |
| MIHON_GITHUB_RELEASE: true | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| get_tag: | |
| if: github.repository == 'mihonapp/mihon' | |
| name: Extract tag name | |
| runs-on: 'ubuntu-24.04' | |
| outputs: | |
| tag: ${{ steps.extract.outputs.tag }} | |
| steps: | |
| - name: Get tag name | |
| id: extract | |
| run: echo "tag=${GITHUB_REF/refs\/tags\//}" >> $GITHUB_OUTPUT | |
| build: | |
| if: github.repository == 'mihonapp/mihon' | |
| name: Build | |
| runs-on: 'ubuntu-24.04' | |
| needs: get_tag | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | |
| - name: Set up JDK | |
| uses: actions/setup-java@b6effb05e454b25005698d916606bdc6ffcbf961 # v5.7.0 | |
| with: | |
| java-version-file: .github/.java-version | |
| distribution: temurin | |
| - name: Set up Gradle | |
| uses: gradle/actions/setup-gradle@3f131e8634966bd73d06cc69884922b02e6faf92 # v6.2.0 | |
| - name: Build | |
| run: ./gradlew assembleRelease -Pinclude-telemetry -Penable-updater | |
| env: | |
| storeFileBase64: ${{ secrets.SIGNING_KEY }} | |
| storePassword: ${{ secrets.KEY_STORE_PASSWORD }} | |
| keyAlias: ${{ secrets.ALIAS }} | |
| keyPassword: ${{ secrets.KEY_PASSWORD }} | |
| - name: Rename APK | |
| run: | | |
| set -e | |
| mv app/build/outputs/apk/release/app-universal-release.apk mihon-${{ needs.get_tag.outputs.tag }}.apk | |
| mv app/build/outputs/apk/release/app-arm64-v8a-release.apk mihon-arm64-v8a-${{ needs.get_tag.outputs.tag }}.apk | |
| mv app/build/outputs/apk/release/app-armeabi-v7a-release.apk mihon-armeabi-v7a-${{ needs.get_tag.outputs.tag }}.apk | |
| mv app/build/outputs/apk/release/app-x86-release.apk mihon-x86-${{ needs.get_tag.outputs.tag }}.apk | |
| mv app/build/outputs/apk/release/app-x86_64-release.apk mihon-x86_64-${{ needs.get_tag.outputs.tag }}.apk | |
| - name: Upload APK | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 | |
| with: | |
| name: mihon | |
| path: | | |
| mihon-${{ needs.get_tag.outputs.tag }}.apk | |
| mihon-arm64-v8a-${{ needs.get_tag.outputs.tag }}.apk | |
| mihon-armeabi-v7a-${{ needs.get_tag.outputs.tag }}.apk | |
| mihon-x86-${{ needs.get_tag.outputs.tag }}.apk | |
| mihon-x86_64-${{ needs.get_tag.outputs.tag }}.apk | |
| build_foss: | |
| if: github.repository == 'mihonapp/mihon' | |
| name: Build (FOSS) | |
| runs-on: ubuntu-24.04 | |
| needs: get_tag | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | |
| - name: Set up JDK | |
| uses: actions/setup-java@b6effb05e454b25005698d916606bdc6ffcbf961 # v5.7.0 | |
| with: | |
| java-version-file: .github/.java-version | |
| distribution: temurin | |
| - name: Set up Gradle | |
| uses: gradle/actions/setup-gradle@3f131e8634966bd73d06cc69884922b02e6faf92 # v6.2.0 | |
| with: | |
| cache-disabled: true | |
| - name: Build | |
| run: ./gradlew assembleFoss -Penable-updater | |
| env: | |
| storeFileBase64: ${{ secrets.SIGNING_KEY }} | |
| storePassword: ${{ secrets.KEY_STORE_PASSWORD }} | |
| keyAlias: ${{ secrets.ALIAS }} | |
| keyPassword: ${{ secrets.KEY_PASSWORD }} | |
| - name: Rename APK | |
| run: | | |
| set -e | |
| mv app/build/outputs/apk/foss/app-universal-foss.apk mihon-${{ needs.get_tag.outputs.tag }}-foss.apk | |
| - name: Upload APK | |
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 | |
| with: | |
| name: mihon-foss | |
| path: mihon-${{ needs.get_tag.outputs.tag }}-foss.apk | |
| release: | |
| if: github.repository == 'mihonapp/mihon' | |
| name: Create GitHub Release | |
| runs-on: ubuntu-24.04 | |
| needs: [get_tag, build, build_foss] | |
| steps: | |
| - name: Download all artifacts | |
| uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1 | |
| with: | |
| merge-multiple: true | |
| - name: Delete all artifacts | |
| uses: geekyeggo/delete-artifact@176a747ab7e287e3ff4787bf8a148716375ca118 # v6.0.0 | |
| with: | |
| failOnError: false | |
| name: | | |
| mihon | |
| mihon-foss | |
| - name: Create GitHub Release | |
| uses: softprops/action-gh-release@3d0d9888cb7fd7b750713d6e236d1fcb99157228 # v3.0.2 | |
| with: | |
| tag_name: ${{ needs.get_tag.outputs.tag }} | |
| name: Mihon ${{ needs.get_tag.outputs.tag }} | |
| body: | | |
| Consider supporting the development on [Patreon](https://www.patreon.com/mihon/membership) or [OpenCollective](https://opencollective.com/mihon/contribute) to keep Mihon improving! | |
| Check out the [past release notes](https://github.com/mihonapp/mihon/releases) if you're upgrading from an earlier version. | |
| <!--> | |
| <!--> | |
| > [!TIP] | |
| > | |
| > ### If you are unsure which version to download then go with `mihon-${{ needs.get_tag.outputs.tag }}.apk` | |
| files: | | |
| mihon-${{ needs.get_tag.outputs.tag }}.apk | |
| mihon-${{ needs.get_tag.outputs.tag }}-foss.apk | |
| mihon-arm64-v8a-${{ needs.get_tag.outputs.tag }}.apk | |
| mihon-armeabi-v7a-${{ needs.get_tag.outputs.tag }}.apk | |
| mihon-x86-${{ needs.get_tag.outputs.tag }}.apk | |
| mihon-x86_64-${{ needs.get_tag.outputs.tag }}.apk | |
| draft: true | |
| prerelease: false | |
| token: ${{ secrets.MIHON_BOT_TOKEN }} |