-
Notifications
You must be signed in to change notification settings - Fork 10
47 lines (38 loc) · 1.4 KB
/
gradle.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
name: CI
on: [push, pull_request]
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.ref }}
cancel-in-progress: true
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
java_version: [ 8, 11, 17 ]
steps:
- uses: actions/checkout@v2
- name: Setup Java
uses: actions/setup-java@v2
with:
distribution: 'temurin'
java-version: ${{ matrix.java_version }}
- name: Get Maven version
run: mvn --version |head -1 > mvn-version
- name: Cache Maven dependencies (for J2Cl tests)
id: cache-maven-dependencies
uses: actions/cache@v2
with:
path: ~/.m2/repository/
key: mvn-deps-${{ hashFiles('mvn-version') }}-${{ hashFiles('pom-j2cl-test.xml') }}
- name: Build with Gradle
uses: gradle/gradle-build-action@v1
with:
arguments: :build-logic:build build -Pj2clTest.webdriver=chrome
distributions-cache-enabled: true
dependencies-cache-enabled: true
dependencies-cache-key: '**/*gradle.lockfile'
dependencies-cache-exact: ${{ github.ref == 'refs/heads/master' }}
cache-read-only: ${{ github.ref != 'refs/heads/master' }}
- name: Before Maven cache
if: steps.cache-maven-dependencies.outputs.cache-hit != 'true'
run: shopt -s globstar && rm -rf ~/.m2/repository/**/*-SNAPSHOT/ ~/.m2/repository/org/gwtproject/**/LOCAL/