-
Notifications
You must be signed in to change notification settings - Fork 34
36 lines (32 loc) · 1017 Bytes
/
cabal.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
on: [pull_request]
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
ghc: # should mirror current stable releases: https://www.haskell.org/ghc/download.html
- '9.6'
- '9.4'
- '9.2'
os: [ubuntu-latest, macOS-latest, windows-latest]
steps:
- uses: actions/checkout@v3
- uses: haskell/actions/setup@v2 # https://github.com/haskell/actions/tree/main/setup#haskellactionssetup
with:
ghc-version: ${{ matrix.ghc }}
- name: Cabal cache
uses: actions/cache@v3
env:
cache-name: cache-cabal
with:
path: ~/.cabal
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/*.cabal') }}-${{ hashFiles('**/cabal.project') }}
restore-keys: |
${{ runner.os }}-build-${{ env.cache-name }}-
- name: Cabal update
run: cabal update
- name: Build using cabal
run: cabal build all
- name: Test
run: cabal test all