-
Notifications
You must be signed in to change notification settings - Fork 0
47 lines (40 loc) · 1.2 KB
/
ci.yaml
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: Build & test
on:
push:
jobs:
build:
name: CI
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
stack_yaml: ['stack.yaml']
steps:
- name: Setup Stack
uses: haskell-actions/setup@v2
with:
enable-stack: true
stack-version: 'latest'
- name: Install system deps
run: 'sudo apt-get -y install freeglut3-dev'
- name: Clone project
uses: actions/checkout@v3
- name: Cache dependencies
uses: actions/cache@v3
with:
path: |
~/.stack
.stack-work
key: ${{ runner.os }}-${{ matrix.stack_yaml }}-${{ hashFiles(matrix.stack_yaml) }}
restore-keys: |
${{ runner.os }}-${{ matrix.stack_yaml }}-
${{ runner.os }}-
- name: 'Set up HLint'
uses: haskell-actions/hlint-setup@v2
- name: 'Run HLint'
uses: haskell-actions/hlint-run@v2
with:
path: src/
fail-on: warning
- name: Build and run tests
run: 'stack build --fast --no-terminal --stack-yaml=${{ matrix.stack_yaml }} --pedantic --haddock --no-haddock-deps --test --bench --no-run-benchmarks'