-
Notifications
You must be signed in to change notification settings - Fork 133
52 lines (48 loc) · 1.56 KB
/
haskell-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
name: CI
on:
pull_request:
push:
branches: [master]
defaults:
run:
shell: bash
jobs:
cabal:
name: ${{ matrix.os }} / ghc ${{ matrix.ghc }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
include:
- { cabal: "3.10", os: ubuntu-latest, ghc: "8.10.7" }
- { cabal: "3.10", os: ubuntu-latest, ghc: "9.0.2" }
- { cabal: "3.10", os: ubuntu-latest, ghc: "9.2.8" }
- { cabal: "3.10", os: ubuntu-latest, ghc: "9.4.6" }
- { cabal: "3.10", os: ubuntu-latest, ghc: "9.6.4" }
- { cabal: "3.10", os: ubuntu-latest, ghc: "9.8.2" }
- { cabal: "3.10", os: ubuntu-latest, ghc: "9.10.1" }
fail-fast: false
steps:
- uses: actions/checkout@v3
if: github.event.action == 'opened' || github.event.action == 'synchronize' || github.event.ref == 'refs/heads/master'
- uses: haskell-actions/setup@v2
id: setup-haskell-cabal
name: Setup Haskell
with:
ghc-version: ${{ matrix.ghc }}
cabal-version: ${{ matrix.cabal }}
- uses: actions/cache@v4
name: Cache ~/.cabal/store
with:
path: ${{ steps.setup-haskell-cabal.outputs.cabal-store }}
key: ${{ runner.os }}-${{ matrix.ghc }}--${{ matrix.cabal }}-cache
- name: Versions
run: |
cabal -V
ghc -V
- name: Build
run: |
cabal configure --haddock-all --enable-tests --enable-benchmarks --benchmark-option=-l
cabal build all --write-ghc-environment-files=always
- name: Test
run: |
cabal test all