17
17
strategy :
18
18
fail-fast : false
19
19
matrix :
20
- ghc : ["9.0.1 ", "8.10.7", "8.8.4", "8.6.5"]
21
- os : [ubuntu-latest]
20
+ ghc : ["9.2.2", "9.0.2 ", "8.10.7", "8.8.4", "8.6.5"]
21
+ os : [ubuntu-latest, macOS-latest, windows-latest ]
22
22
23
23
steps :
24
24
- uses : actions/checkout@v2
@@ -27,57 +27,46 @@ jobs:
27
27
id : setup-haskell
28
28
with :
29
29
ghc-version : ${{ matrix.ghc }}
30
- cabal-version : 3.4.0 .0
30
+ cabal-version : 3.6.2 .0
31
31
32
32
- name : Set some window specific things
33
33
if : matrix.os == 'windows-latest'
34
34
run : echo 'EXE_EXT=.exe' >> $GITHUB_ENV
35
35
36
36
- name : Configure project
37
- run : cabal configure --enable-tests --enable-benchmarks --write-ghc-environment-files=ghc8.4.4+
37
+ run : |
38
+ cabal configure --enable-tests --enable-benchmarks --write-ghc-environment-files=ghc8.4.4+
39
+ APPEND=1 ./scripts/gen-cabal-project-local.sh
40
+ echo "cabal.project.local:"
41
+ cat cabal.project.local
38
42
39
- - name : Restore cabal cache
40
- uses : haskell -works/cabal-cache-action @v1
43
+ - name : Cabal cache over S3
44
+ uses : action -works/cabal-cache-s3 @v1
41
45
env :
42
46
AWS_ACCESS_KEY_ID : ${{ secrets.AWS_ACCESS_KEY_ID }}
43
47
AWS_SECRET_ACCESS_KEY : ${{ secrets.AWS_SECRET_ACCESS_KEY }}
44
- BINARY_CACHE_REGION : ${{ secrets.BINARY_CACHE_REGION }}
45
- BINARY_CACHE_THREADS : ${{ secrets.BINARY_CACHE_THREADS }}
46
- BINARY_CACHE_URI : ${{ secrets.BINARY_CACHE_URI }}
47
48
with :
48
- args : |
49
- sync-from-archive \
50
- --threads "$BINARY_CACHE_THREADS" \
51
- --archive-uri "$BINARY_CACHE_URI" \
52
- --region "$BINARY_CACHE_REGION" \
53
- --store-path "${{ steps.setup-haskell.outputs.cabal-store }}"
49
+ region : us-west-2
50
+ dist-dir : dist-newstyle
51
+ store-path : ${{ steps.setup-haskell.outputs.cabal-store }}
52
+ threads : 16
53
+ archive-uri : ${{ secrets.BINARY_CACHE_URI }}
54
+ skip : " ${{ secrets.BINARY_CACHE_URI == '' }}"
55
+
56
+ - name : Cabal cache over HTTPS
57
+ uses : action-works/cabal-cache-s3@v1
58
+ with :
59
+ dist-dir : dist-newstyle
60
+ store-path : ${{ steps.setup-haskell.outputs.cabal-store }}
61
+ threads : 16
62
+ archive-uri : https://cache.haskellworks.io/archive
63
+ skip : " ${{ secrets.BINARY_CACHE_URI != '' }}"
54
64
55
65
- name : Build
56
- # Try building it twice in case of flakey builds on Windows
57
- run : |
58
- cabal build all --enable-tests --enable-benchmarks --write-ghc-environment-files=ghc8.4.4+ || \
59
- cabal build all --enable-tests --enable-benchmarks --write-ghc-environment-files=ghc8.4.4+ -j1
66
+ run : cabal build all --enable-tests --enable-benchmarks
60
67
61
68
- name : Test
62
- run : |
63
- cabal test all --enable-tests --enable-benchmarks --write-ghc-environment-files=ghc8.4.4+
64
-
65
- - name : Save cabal cache
66
- uses : haskell-works/cabal-cache-action@v1
67
- if : ${{ always() }}
68
- env :
69
- AWS_ACCESS_KEY_ID : ${{ secrets.AWS_ACCESS_KEY_ID }}
70
- AWS_SECRET_ACCESS_KEY : ${{ secrets.AWS_SECRET_ACCESS_KEY }}
71
- BINARY_CACHE_REGION : ${{ secrets.BINARY_CACHE_REGION }}
72
- BINARY_CACHE_THREADS : ${{ secrets.BINARY_CACHE_THREADS }}
73
- BINARY_CACHE_URI : ${{ secrets.BINARY_CACHE_URI }}
74
- with :
75
- args : |
76
- sync-to-archive \
77
- --threads "$BINARY_CACHE_THREADS" \
78
- --archive-uri "$BINARY_CACHE_URI" \
79
- --region "$BINARY_CACHE_REGION" \
80
- --store-path "${{ steps.setup-haskell.outputs.cabal-store }}"
69
+ run : cabal test all --enable-tests --enable-benchmarks
81
70
82
71
check :
83
72
needs : build
0 commit comments