-
-
Notifications
You must be signed in to change notification settings - Fork 27
59 lines (47 loc) · 1.43 KB
/
android.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
name: Android CI
on:
push:
branches:
- '*'
- '!l10n_dev'
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 100
- name: Fetch all tags
run: git fetch origin +refs/tags/*:refs/tags/*
- name: Set up JDK 11
uses: actions/setup-java@v2
with:
java-version: '11'
java-package: jdk
distribution: 'adopt'
cache: gradle
- name: Validate gradle wrapper
uses: gradle/wrapper-validation-action@v1
- name: Decrypt secret
if: ${{ false }}
run: |
gpg -d --passphrase "${{ secrets.KAU_TAR_SECRET }}" --batch "files/kau_github.tar.gpg" > "files/kau_github.tar"
tar xvf files/kau_github.tar -C files
- name: Checkout Gradle Build Cache
if: ${{ steps.self_hosted.outputs.FLAG != 'self-hosted' }}
uses: actions/cache@v2
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
!~/.gradle/wrapper/dists/**/gradle*.zip
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*') }}
restore-keys: |
gradle-${{ runner.os }}-
- name: Grant execute permission for gradlew
run: chmod +x gradlew
- name: Android Git Version
run: ./gradlew --quiet androidGitVersion
- name: Check and Test
run: ./gradlew spotlessCheck lintRelease testReleaseUnitTest