-
Notifications
You must be signed in to change notification settings - Fork 371
90 lines (74 loc) · 2.54 KB
/
voice.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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
name: CI/CD
on:
push:
branches:
- main
tags:
- '*'
pull_request:
branches:
- main
env:
GRADLE_OPTS: -Dorg.gradle.jvmargs="-Xmx3072m -XX:MaxMetaspaceSize=1g -Xms512m -XX:+HeapDumpOnOutOfMemoryError"
ANDROID_PUBLISHER_CREDENTIALS: ${{ secrets.ANDROID_PUBLISHER_CREDENTIALS }}
SIGNING_KEYSTORE_PLAY: ${{ secrets.SIGNING_KEYSTORE }}
SIGNING_PROPERTIES_PLAY: ${{ secrets.SIGNING_PROPERTIES }}
SIGNING_KEYSTORE_GITHUB: ${{ secrets.SIGNING_KEYSTORE_GITHUB }}
SIGNING_PROPERTIES_GITHUB: ${{ secrets.SIGNING_PROPERTIES_GITHUB }}
GOOGLE_SERVICES: ${{ secrets.GOOGLE_SERVICES }}
VOICE_USE_PROPRIETARY_LIBRARIES: "true"
jobs:
test:
if: github.event_name == 'push' || github.event_name == 'pull_request'
timeout-minutes: 60
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
- name: Setup Gradle
uses: gradle/gradle-build-action@v2
- name: Set up JDK
uses: actions/setup-java@v3.13.0
with:
distribution: 'zulu'
java-version: 17
- name: Setup Signing
run: ./ci_signing_setup.sh
- name: Test
run: ./gradlew testDebugUnitTest lintKotlin :app:lintDebug :app:assembleDebug :scripts:build
- uses: actions/upload-artifact@v3
if: always()
with:
name: "Artifacts"
path: |
artifacts/
app/build/reports/*.html
app/build/outputs/apk/debug/app-debug.apk
- name: Publish Test Report
uses: mikepenz/action-junit-report@v4
if: always()
with:
report_paths: '**/test-results/**/TEST-*.xml'
release:
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/')
timeout-minutes: 60
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4
- name: Set up JDK
uses: actions/setup-java@v3.13.0
with:
distribution: 'zulu'
java-version: 17
- name: Setup Gradle
uses: gradle/gradle-build-action@v2
- name: Setup Signing
run: ./ci_signing_setup.sh
- name: Publish to Google Play
run: ./gradlew app:publishReleaseBundle -Pvoice.signing.play=true
- name: Build Github APK
run: ./gradlew app:assembleRelease -Pvoice.signing.play=false
- name: Github Release
uses: softprops/action-gh-release@v1
with:
generate_release_notes: true
files: app/build/outputs/apk/release/app-release.apk