-
Notifications
You must be signed in to change notification settings - Fork 1
58 lines (52 loc) · 1.63 KB
/
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
55
56
57
58
name: Release
on:
push:
tags:
- 'v*'
- 'camp23.*'
jobs:
build:
name: Build and sign APK
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Get tag
id: var
run: echo ::set-output name=tag::${GITHUB_REF#refs/*/}
- name: Build APK
run: bash ./gradlew assembleRelease
- name: Sign APK
id: sign_apk
uses: r0adkll/sign-android-release@v1
with:
releaseDirectory: app/build/outputs/apk/release
signingKeyBase64: ${{ secrets.SIGNING_KEY_BASE64 }}
alias: ${{ secrets.ALIAS }}
keyStorePassword: ${{ secrets.KEY_STORE_PASSWORD }}
keyPassword: ${{ secrets.KEY_PASSWORD }}
- name: Build Changelog
id: changelog
uses: ardalanamini/auto-changelog@v2
with:
token: ${{ secrets.GITHUB_TOKEN }}
- name: Create Release
uses: actions/create-release@v1
id: create_release
with:
draft: false
prerelease: false
release_name: Release ${{ github.ref }}
tag_name: ${{ github.ref }}
body: |
${{ steps.changelog.outputs.changelog }}
env:
GITHUB_TOKEN: ${{ github.token }}
- name: Upload APK
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ github.token }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ${{ steps.sign_apk.outputs.signedReleaseFile }}
asset_name: notificationlightbridge-${{ steps.var.outputs.tag }}.apk
asset_content_type: application/zip