-
Notifications
You must be signed in to change notification settings - Fork 0
41 lines (35 loc) · 987 Bytes
/
AndroidBuild.yml
File metadata and controls
41 lines (35 loc) · 987 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
name: AndroidBuild
on:
pull_request:
branches:
- main
push:
branches:
- main
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4.2.2
- name: Setup Java JDK
uses: actions/setup-java@v3.14.1
with:
distribution: 'adopt'
java-version: '17'
- name: Grant execute permission for gradlew
run: chmod +x ./gradlew
- name: Build with Gradle
run: ./gradlew build
- name: Rename APK with timestamp
run: |
TIMESTAMP=$(TZ="Asia/Kolkata" date +'%d-%m-%Y-%H-%M')
mkdir -p output-apk
cp app/build/outputs/apk/debug/app-debug.apk "output-apk/SuperApp_${TIMESTAMP}.apk"
- name: List APK files
run: ls -lh output-apk
- name: Upload APK Artifact
uses: actions/upload-artifact@v4.6.2
with:
name: "SuperApp Build"
path: output-apk/SuperApp_*.apk