Skip to content

Commit 3180d79

Browse files
committed
Add basic GH CI
1 parent c0dcc25 commit 3180d79

File tree

1 file changed

+49
-0
lines changed

1 file changed

+49
-0
lines changed

.github/workflows/haskell.yml

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
name: CI
2+
on:
3+
push:
4+
branches:
5+
- master
6+
pull_request:
7+
types:
8+
- opened
9+
- synchronize
10+
jobs:
11+
build:
12+
strategy:
13+
fail-fast: false
14+
matrix:
15+
os: [macos-latest, ubuntu-latest]
16+
cabal: ["3.4"]
17+
ghc: ["8.10.7"]
18+
19+
runs-on: ${{ matrix.os }}
20+
21+
steps:
22+
- uses: actions/checkout@v2
23+
- uses: haskell/actions/setup@v1
24+
id: setup-haskell-cabal
25+
with:
26+
ghc-version: ${{ matrix.ghc }}
27+
cabal-version: ${{ matrix.cabal }}
28+
- name: Cabal Update
29+
run: |
30+
cabal v2-update
31+
cabal v2-freeze $CONFIG
32+
- uses: actions/[email protected]
33+
with:
34+
path: |
35+
${{ steps.setup-haskell-cabal.outputs.cabal-store }}
36+
dist-newstyle
37+
key: ${{ runner.os }}-${{ matrix.ghc }}-${{ hashFiles('cabal.project.freeze') }}
38+
restore-keys: |
39+
${{ runner.os }}-${{ matrix.ghc }}-${{ matrix.cabal }}-
40+
- name: Build all
41+
run: |
42+
cabal build all
43+
cabal sdist all
44+
- name: Run tests
45+
run: |
46+
cabal test all
47+
- name: Build haddock
48+
run: |
49+
cabal haddock all

0 commit comments

Comments
 (0)