Skip to content

Commit d6c6b50

Browse files
committed
github action test
1 parent a3b5529 commit d6c6b50

File tree

2 files changed

+24
-92
lines changed

2 files changed

+24
-92
lines changed

.github/workflows/docker-image.yml

Lines changed: 0 additions & 57 deletions
This file was deleted.

.github/workflows/haskell.yml

Lines changed: 24 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,7 @@ name: Haskell CI
22

33
on:
44
push:
5-
branches:
6-
- "*"
5+
branches: [ "main", "ci" ]
76
pull_request:
87
branches: [ "main" ]
98

@@ -13,47 +12,37 @@ permissions:
1312
jobs:
1413
build:
1514

16-
strategy:
17-
matrix:
18-
os: [ ubuntu-22.04 ]
19-
haskell: [ 9.4.7 ]
15+
runs-on: ubuntu-latest
2016

21-
runs-on: ${{ matrix.os }}
17+
container:
18+
image: haskell:9.8.2
2219

2320
steps:
24-
- uses: actions/checkout@v3
25-
26-
- name: Check Haskell version
27-
run: |
28-
ghcup --version
29-
ghc --version
30-
- name: Install Haskell ${{ matrix.haskell }}
31-
run: |
32-
ghcup install ghc ${{ matrix.haskell }}
33-
ghcup set ghc ${{ matrix.haskell }}
34-
- name: Check Haskell version
35-
run: ghc --version
36-
37-
- name: Cache
38-
uses: actions/cache@v3
39-
env:
40-
# increment when you want to rebuild the cache
41-
cache-name: cache-cabal-v6
42-
with:
43-
path: /home/runner/.local/state/cabal
44-
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/*.cabal') }}-${{ hashFiles('**/cabal.project') }}
45-
restore-keys: |
46-
${{ runner.os }}-build-${{ env.cache-name }}-
47-
${{ runner.os }}-build-
48-
${{ runner.os }}-
49-
21+
- uses: actions/checkout@v4
22+
23+
# - uses: actions/setup-haskell@v1
24+
# with:
25+
# ghc-version: '9.6'
26+
# cabal-version: '3.2'
27+
28+
# - name: Cache
29+
# uses: actions/cache@v3
30+
# env:
31+
# cache-name: cache-cabal
32+
# with:
33+
# path: ~/.cabal
34+
# key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/*.cabal') }}-${{ hashFiles('**/cabal.project') }}
35+
# restore-keys: |
36+
# ${{ runner.os }}-build-${{ env.cache-name }}-
37+
# ${{ runner.os }}-build-
38+
# ${{ runner.os }}-
5039

5140
- name: Install dependencies
5241
run: |
5342
cabal update
5443
cabal build --only-dependencies --enable-tests --enable-benchmarks
5544
- name: Build
5645
run: cabal build --enable-tests --enable-benchmarks all
57-
- name: Run tests
58-
run: cabal test all
46+
- name: Test
47+
run: cabal test
5948

0 commit comments

Comments
 (0)