-
Notifications
You must be signed in to change notification settings - Fork 170
56 lines (47 loc) · 1.29 KB
/
build.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
48
49
50
51
52
53
54
55
56
name: CI
on:
pull_request:
push:
schedule:
- cron: '0 0 * * 0'
jobs:
cabal:
strategy:
matrix:
ghc:
- "8.8"
- "8.10"
- "9.0"
- "9.2"
name: GHC ${{ matrix.ghc }}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: haskell-actions/setup@v2
id: setup-haskell-cabal
with:
ghc-version: ${{ matrix.ghc }}
- name: Configure
run: |
cabal configure --enable-tests --enable-benchmarks --enable-documentation --test-show-details=direct --write-ghc-environment-files=always
- name: Freeze
run: |
cabal freeze
- uses: actions/cache@v2
name: Cache
with:
path: ${{ steps.setup-haskell-cabal.outputs.cabal-store }}
key: ${{ runner.os }}-${{ matrix.ghc }}-${{ hashFiles('cabal.project.freeze') }}
- name: Build dependencies
run: |
cabal build all --only-dependencies
- name: Build
run: |
cabal build all --enable-tests
- name: Test
run: |
export PATH=$PATH:/usr/lib/postgresql/$(ls /usr/lib/postgresql | head -n 1)/bin
cabal test all --enable-tests
- name: Build documentation
run: |
cabal haddock all