-
Notifications
You must be signed in to change notification settings - Fork 0
37 lines (33 loc) · 1.31 KB
/
basic.yml
File metadata and controls
37 lines (33 loc) · 1.31 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
# origin : https://github.com/googlesamples/android-custom-lint-rules/blob/main/.github/workflows/basic.yml
name: CI
on: [push]
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Cache Gradle and wrapper
uses: actions/cache@v4
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }}
restore-keys: ${{ runner.os }}-gradle-
- name: Validate gradle wrapper
uses: gradle/actions/wrapper-validation@v4
- name: Set up JDK 21
uses: actions/setup-java@v4
with:
distribution: 'zulu'
java-version: '21'
cache: 'gradle'
# AGP 8.2 requires 34.0.0-rc3 - see https://issuetracker.google.com/issues/236167971#comment36
# and https://github.com/actions/runner-images/issues/7506#issuecomment-1533097084
# TODO: Remove when AGP updates Build Tools to 34.0.0 and pre-installed in the runner
#- name: Install Android Build Tools 34.0.0-rc3
# run: yes | $ANDROID_HOME/cmdline-tools/latest/bin/sdkmanager "build-tools;34.0.0-rc3"
# shell: bash
- name: Build with Gradle
run: ./gradlew :lint:build :lint:test