Skip to content

Commit 16807a6

Browse files
committed
Refactor build workflow to include Telegram notification and upload artifact
1 parent 1af489c commit 16807a6

File tree

1 file changed

+21
-13
lines changed

1 file changed

+21
-13
lines changed

.github/workflows/build.yml

Lines changed: 21 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -48,22 +48,30 @@ jobs:
4848
- name: Build Android Release
4949
run: cd android && ./gradlew assembleRelease
5050

51-
- name: send telegram message on push
52-
uses: appleboy/telegram-action@master
51+
- name: Upload Artifact
52+
uses: actions/upload-artifact@v4
5353
with:
54-
to: ${{ secrets.TELEGRAM_TO }}
55-
token: ${{ secrets.TELEGRAM_TOKEN }}
56-
document: "./android/app/build/outputs/apk/release/Tech_Triangle-arm64-v8a.apk"
57-
message: |
58-
${{ github.actor }} created commit:
59-
Commit message: ${{ github.event.commits[0].message }}
54+
name: tech-triangle
55+
path: android/app/build/outputs/apk/release/Tech_Triangle-arm64-v8a.apk
6056

61-
Repository: ${{ github.repository }}
6257

63-
See changes: https://github.com/${{ github.repository }}/commit/${{github.sha}}
6458

65-
- name: Upload Artifact
66-
uses: actions/upload-artifact@v4
59+
send_to_telegram:
60+
name: Send Apk to Asurraa telegram group
61+
needs: build_apk
62+
runs-on: ubuntu-latest
63+
steps:
64+
- name: Download Artifact
65+
uses: actions/download-artifact@v2
6766
with:
6867
name: tech-triangle
69-
path: android/app/build/outputs/apk/release/Tech_Triangle-arm64-v8a.apk
68+
- name: Display structure of downloaded files
69+
run: ls -R
70+
- uses: actions/checkout@master
71+
- name: send apk file
72+
uses: appleboy/telegram-action@master
73+
with:
74+
to: ${{ secrets.TELEGRAM_TO }}
75+
token: ${{ secrets.TELEGRAM_TOKEN }}
76+
message: ${{github.event.head_commit.message}}
77+
document: Tech_Triangle-arm64-v8a.apk

0 commit comments

Comments
 (0)