-
Notifications
You must be signed in to change notification settings - Fork 1
75 lines (67 loc) · 1.84 KB
/
ci.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
# This file was originally automatically generated by sbt-github-actions
# using the githubWorkflowGenerate task. AFAICT sbt-github-actions doesn't
# support adding "Services" to the build via the sbt DSL, so we had to
# remove the plugin and manually modify the generated files.
name: Continuous Integration
on:
pull_request:
branches: ['**']
push:
branches: ['**']
tags: [v*]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
jobs:
build:
name: Build and Test
strategy:
matrix:
os:
- ubuntu-latest
scala:
- 2.13.8
java:
- temurin@8
- temurin@11
database:
- mysql:8
runs-on: ${{ matrix.os }}
env:
LOG_LEVEL: info
services:
mysql:
image: ${{ matrix.database }}
env:
MYSQL_ROOT_PASSWORD: password
ports:
- 3306:3306
steps:
- name: Checkout current branch (full)
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Setup Java (temurin@8)
if: matrix.java == 'temurin@8'
uses: actions/setup-java@v2
with:
distribution: temurin
java-version: 8
- name: Setup Java (temurin@11)
if: matrix.java == 'temurin@11'
uses: actions/setup-java@v2
with:
distribution: temurin
java-version: 11
- name: Cache sbt
uses: actions/cache@v2
with:
path: |
~/.sbt
~/.ivy2/cache
~/.coursier/cache/v1
~/.cache/coursier/v1
~/AppData/Local/Coursier/Cache/v1
~/Library/Caches/Coursier/v1
key: ${{ runner.os }}-sbt-cache-v2-${{ hashFiles('**/*.sbt') }}-${{ hashFiles('project/build.properties') }}
- name: Build project
run: sbt ++${{ matrix.scala }} test