From d8c311fbd7a5581a3734fb861af5e65207c012bf Mon Sep 17 00:00:00 2001 From: Sadwhy <99601717+Sadwhy@users.noreply.github.com> Date: Fri, 5 Apr 2024 22:36:27 +0600 Subject: [PATCH 1/3] Include all Splits for discord (#324) --- .github/workflows/beta.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/beta.yml b/.github/workflows/beta.yml index 6f0a10cd..95bb2174 100644 --- a/.github/workflows/beta.yml +++ b/.github/workflows/beta.yml @@ -104,6 +104,10 @@ jobs: fi contentbody=$( jq -nc --arg msg "Alpha-Build: <@&1225347048321191996> **$VERSION**:" --arg commits "$commit_messages" '{"content": ($msg + "\n" + $commits)}' ) curl -F "payload_json=${contentbody}" -F "dantotsu_debug=@app/build/outputs/apk/google/alpha/app-google-universal-alpha.apk" ${{ secrets.DISCORD_WEBHOOK }} + curl -F "dantotsu_debug=@app/build/outputs/apk/google/alpha/app-google-armeabi-v7a-alpha.apk" ${{ secrets.DISCORD_WEBHOOK }} + curl -F "dantotsu_debug=@app/build/outputs/apk/google/alpha/app-google-arm64-v8a-alpha.apk" ${{ secrets.DISCORD_WEBHOOK }} + curl -F "dantotsu_debug=@app/build/outputs/apk/google/alpha/app-google-x86-alpha.apk" ${{ secrets.DISCORD_WEBHOOK }} + curl -F "dantotsu_debug=@app/build/outputs/apk/google/alpha/app-google-x86_64-alpha.apk" ${{ secrets.DISCORD_WEBHOOK }} #Telegram curl -F "chat_id=${{ secrets.TELEGRAM_CHANNEL_ID }}" \ From e4574d6c03cf105a8a7619ab0fc4240ce91ec6f8 Mon Sep 17 00:00:00 2001 From: rebel onion <87634197+rebelonion@users.noreply.github.com> Date: Fri, 5 Apr 2024 11:40:11 -0500 Subject: [PATCH 2/3] feat: send all apks to telegram --- .github/workflows/beta.yml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/.github/workflows/beta.yml b/.github/workflows/beta.yml index 95bb2174..7165aeed 100644 --- a/.github/workflows/beta.yml +++ b/.github/workflows/beta.yml @@ -114,6 +114,22 @@ jobs: -F "document=@app/build/outputs/apk/google/alpha/app-google-universal-alpha.apk" \ -F "caption=Alpha-Build: ${VERSION}: ${commit_messages}" \ https://api.telegram.org/bot${{ secrets.TELEGRAM_BOT_TOKEN }}/sendDocument + curl -F "chat_id=${{ secrets.TELEGRAM_CHANNEL_ID }}" \ + -F "document=@app/build/outputs/apk/google/alpha/app-google-armeabi-v7a-alpha.apk" \ + -F "caption=armeabi-v7a" \ + https://api.telegram.org/bot${{ secrets.TELEGRAM_BOT_TOKEN }}/sendDocument + curl -F "chat_id=${{ secrets.TELEGRAM_CHANNEL_ID }}" \ + -F "document=@app/build/outputs/apk/google/alpha/app-google-arm64-v8a-alpha.apk" \ + -F "caption=arm64-v8a" \ + https://api.telegram.org/bot${{ secrets.TELEGRAM_BOT_TOKEN }}/sendDocument + curl -F "chat_id=${{ secrets.TELEGRAM_CHANNEL_ID }}" \ + -F "document=@app/build/outputs/apk/google/alpha/app-google-x86-alpha.apk" \ + -F "caption=x86" \ + https://api.telegram.org/bot${{ secrets.TELEGRAM_BOT_TOKEN }}/sendDocument + curl -F "chat_id=${{ secrets.TELEGRAM_CHANNEL_ID }}" \ + -F "document=@app/build/outputs/apk/google/alpha/app-google-x86_64-alpha.apk" \ + -F "caption=x86_64" \ + https://api.telegram.org/bot${{ secrets.TELEGRAM_BOT_TOKEN }}/sendDocument env: COMMIT_LOG: ${{ env.COMMIT_LOG }} From ce11c71e95ef24ccc5d4c6bd8cd936ebfe9376dc Mon Sep 17 00:00:00 2001 From: Sadwhy <99601717+Sadwhy@users.noreply.github.com> Date: Sat, 6 Apr 2024 00:43:22 +0600 Subject: [PATCH 3/3] Fixed artifact upload (#326) --- .github/workflows/beta.yml | 53 +++++++++++++++++++++----------------- 1 file changed, 30 insertions(+), 23 deletions(-) diff --git a/.github/workflows/beta.yml b/.github/workflows/beta.yml index 7165aeed..a475edfe 100644 --- a/.github/workflows/beta.yml +++ b/.github/workflows/beta.yml @@ -48,9 +48,11 @@ jobs: echo "COMMIT_LOG=${COMMIT_LOGS}" >> $GITHUB_ENV # Debugging: Print the variable to check its content echo "$COMMIT_LOGS" + echo "$COMMIT_LOGS" > commit_log.txt shell: /usr/bin/bash -e {0} env: CI: true + continue-on-error: true - name: Save Current SHA for Next Run run: echo ${{ github.sha }} > last_sha.txt @@ -75,7 +77,7 @@ jobs: - name: List files in the directory run: ls -l - + - name: Make gradlew executable run: chmod +x ./gradlew @@ -85,11 +87,15 @@ jobs: - name: Upload Build Artifacts uses: actions/upload-artifact@v4.3.1 with: - name: APKs - path: | - app/build/outputs/apk/google/alpha/*/*.apk - app/build/outputs/apk/google/alpha/*/*/*.apk - app/build/outputs/apk/google/alpha/*/*/*/*.apk + name: Dantotsu-Split + retention-days: 5 + compression-level: 9 + path: | + app/build/outputs/apk/google/alpha/app-google-universal-alpha.apk + app/build/outputs/apk/google/alpha/app-google-armeabi-v7a-alpha.apk + app/build/outputs/apk/google/alpha/app-google-arm64-v8a-alpha.apk + app/build/outputs/apk/google/alpha/app-google-x86-alpha.apk + app/build/outputs/apk/google/alpha/app-google-x86_64-alpha.apk - name: Upload APK to Discord and Telegram if: ${{ github.repository == 'rebelonion/Dantotsu' }} @@ -108,28 +114,24 @@ jobs: curl -F "dantotsu_debug=@app/build/outputs/apk/google/alpha/app-google-arm64-v8a-alpha.apk" ${{ secrets.DISCORD_WEBHOOK }} curl -F "dantotsu_debug=@app/build/outputs/apk/google/alpha/app-google-x86-alpha.apk" ${{ secrets.DISCORD_WEBHOOK }} curl -F "dantotsu_debug=@app/build/outputs/apk/google/alpha/app-google-x86_64-alpha.apk" ${{ secrets.DISCORD_WEBHOOK }} - + #Telegram + curl -F "chat_id=${{ secrets.TELEGRAM_CHANNEL_ID }}" \ + -F "document=@app/build/outputs/apk/google/alpha/app-google-armeabi-v7a-alpha.apk" \ + https://api.telegram.org/bot${{ secrets.TELEGRAM_BOT_TOKEN }}/sendDocument + curl -F "chat_id=${{ secrets.TELEGRAM_CHANNEL_ID }}" \ + -F "document=@app/build/outputs/apk/google/alpha/app-google-arm64-v8a-alpha.apk" \ + https://api.telegram.org/bot${{ secrets.TELEGRAM_BOT_TOKEN }}/sendDocument + curl -F "chat_id=${{ secrets.TELEGRAM_CHANNEL_ID }}" \ + -F "document=@app/build/outputs/apk/google/alpha/app-google-x86-alpha.apk" \ + https://api.telegram.org/bot${{ secrets.TELEGRAM_BOT_TOKEN }}/sendDocument + curl -F "chat_id=${{ secrets.TELEGRAM_CHANNEL_ID }}" \ + -F "document=@app/build/outputs/apk/google/alpha/app-google-x86_64-alpha.apk" \ + https://api.telegram.org/bot${{ secrets.TELEGRAM_BOT_TOKEN }}/sendDocument curl -F "chat_id=${{ secrets.TELEGRAM_CHANNEL_ID }}" \ -F "document=@app/build/outputs/apk/google/alpha/app-google-universal-alpha.apk" \ -F "caption=Alpha-Build: ${VERSION}: ${commit_messages}" \ https://api.telegram.org/bot${{ secrets.TELEGRAM_BOT_TOKEN }}/sendDocument - curl -F "chat_id=${{ secrets.TELEGRAM_CHANNEL_ID }}" \ - -F "document=@app/build/outputs/apk/google/alpha/app-google-armeabi-v7a-alpha.apk" \ - -F "caption=armeabi-v7a" \ - https://api.telegram.org/bot${{ secrets.TELEGRAM_BOT_TOKEN }}/sendDocument - curl -F "chat_id=${{ secrets.TELEGRAM_CHANNEL_ID }}" \ - -F "document=@app/build/outputs/apk/google/alpha/app-google-arm64-v8a-alpha.apk" \ - -F "caption=arm64-v8a" \ - https://api.telegram.org/bot${{ secrets.TELEGRAM_BOT_TOKEN }}/sendDocument - curl -F "chat_id=${{ secrets.TELEGRAM_CHANNEL_ID }}" \ - -F "document=@app/build/outputs/apk/google/alpha/app-google-x86-alpha.apk" \ - -F "caption=x86" \ - https://api.telegram.org/bot${{ secrets.TELEGRAM_BOT_TOKEN }}/sendDocument - curl -F "chat_id=${{ secrets.TELEGRAM_CHANNEL_ID }}" \ - -F "document=@app/build/outputs/apk/google/alpha/app-google-x86_64-alpha.apk" \ - -F "caption=x86_64" \ - https://api.telegram.org/bot${{ secrets.TELEGRAM_BOT_TOKEN }}/sendDocument env: COMMIT_LOG: ${{ env.COMMIT_LOG }} @@ -141,6 +143,11 @@ jobs: name: last-sha path: last_sha.txt + - name: Upload Commit log as Artifact + uses: actions/upload-artifact@v2 + with: + name: commit-log + path: commit_log.txt - name: Delete Old Pre-Releases id: delete-pre-releases