-
-
Notifications
You must be signed in to change notification settings - Fork 1
51 lines (44 loc) · 1.48 KB
/
android.yml
File metadata and controls
51 lines (44 loc) · 1.48 KB
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
name: CI
on:
push:
tags:
- '*'
jobs:
build:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v2
- name: Use Java 11
uses: actions/setup-java@v1
with:
java-version: 1.11
- name: Build debug apk
run: ./gradlew clean assembleRelease
- name: Get the version
env:
ACTIONS_ALLOW_UNSECURE_COMMANDS: 'true'
run: echo ::set-env name=RELEASE_VERSION::$(echo ${GITHUB_REF:10})
- run: echo "previous_tag=$(git describe --tags --abbrev=0 2>/dev/null || echo '')" >> $GITHUB_ENV
- name: Generate changelog
id: changelog
uses: jaywcjlove/changelog-generator@main
# if: env.previous_tag
with:
token: ${{ secrets.GITHUB_TOKEN }}
# filter: '[R|r]elease[d]\s+\d(\.\d+){0,2}'
- name: Create changelogs
id: changelogs
uses: heineiuo/create-changelogs@master
- name: Create release and upload apk
uses: underwindfall/create-release-with-debugapk@v2.0.0
env:
ACTIONS_ALLOW_UNSECURE_COMMANDS: 'true'
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ env.RELEASE_VERSION }}
asset_path: app/build/outputs/apk/release/app-release.apk
asset_name: app-release.apk
asset_content_type: application/zip
body: |
${{ steps.changelog.outputs.compareurl }}
${{ steps.changelog.outputs.changelog }}