-
-
Notifications
You must be signed in to change notification settings - Fork 46
54 lines (46 loc) · 1.33 KB
/
build-release.yml
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
42
43
44
45
46
47
48
49
50
51
52
53
54
name: Build and release app
on:
workflow_dispatch:
push:
tags:
- 'v*.*'
jobs:
build:
name: Build, sign and release app
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v4
- name: Set up JDK
uses: actions/setup-java@v4
with:
distribution: "zulu"
java-version: "17"
cache: "gradle"
- name: Build APK
run: ./gradlew assembleRelease --no-daemon
- name: Sign APK
uses: ilharp/sign-android-release@v1
id: sign
with:
signingKey: ${{ secrets.KEYSTORE }}
keyAlias: ${{ secrets.SIGNING_KEY_ALIAS }}
keyStorePassword: ${{ secrets.SIGNING_STORE_PASSWORD }}
keyPassword: ${{ secrets.SIGNING_KEY_PASSWORD }}
- name: Rename signed APK
run: |
mv "${{ steps.sign.outputs.signedFile }}" "app-release.apk"
- name: Create changelog
id: changelog
uses: requarks/changelog-action@v1
with:
token: ${{ github.token }}
tag: ${{ github.ref_name }}
- name: Create release
uses: softprops/action-gh-release@v2
with:
body: ${{ steps.changelog.outputs.changes }}
files: "app-release.apk"
fail_on_unmatched_files: true
make_latest: true