Skip to content

Commit bbedbc9

Browse files
authored
Test on more GHC versions. (#214)
Also adds a few missing upper bounds for good measure.
1 parent a5ad8bc commit bbedbc9

2 files changed

Lines changed: 34 additions & 21 deletions

File tree

.github/workflows/haskell-ci.yml

Lines changed: 28 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@
88
#
99
# For more information, see https://github.com/haskell-CI/haskell-ci
1010
#
11-
# version: 0.19.20250330
11+
# version: 0.19.20260624
1212
#
13-
# REGENDATA ("0.19.20250330",["github","haskeline.cabal"])
13+
# REGENDATA ("0.19.20260624",["github","haskeline.cabal"])
1414
#
1515
name: Haskell-CI
1616
on:
@@ -20,6 +20,11 @@ on:
2020
pull_request:
2121
branches:
2222
- master
23+
merge_group:
24+
branches:
25+
- master
26+
workflow_dispatch:
27+
{}
2328
jobs:
2429
linux:
2530
name: Haskell-CI - Linux - ${{ matrix.compiler }}
@@ -32,19 +37,24 @@ jobs:
3237
strategy:
3338
matrix:
3439
include:
35-
- compiler: ghc-9.12.1
40+
- compiler: ghc-9.14.1
41+
compilerKind: ghc
42+
compilerVersion: 9.14.1
43+
setup-method: ghcup
44+
allow-failure: false
45+
- compiler: ghc-9.12.4
3646
compilerKind: ghc
37-
compilerVersion: 9.12.1
47+
compilerVersion: 9.12.4
3848
setup-method: ghcup
3949
allow-failure: false
40-
- compiler: ghc-9.10.1
50+
- compiler: ghc-9.10.3
4151
compilerKind: ghc
42-
compilerVersion: 9.10.1
52+
compilerVersion: 9.10.3
4353
setup-method: ghcup
4454
allow-failure: false
45-
- compiler: ghc-9.8.2
55+
- compiler: ghc-9.8.4
4656
compilerKind: ghc
47-
compilerVersion: 9.8.2
57+
compilerVersion: 9.8.4
4858
setup-method: ghcup
4959
allow-failure: false
5060
- compiler: ghc-9.6.5
@@ -110,8 +120,8 @@ jobs:
110120
chmod a+x "$HOME/.ghcup/bin/ghcup"
111121
- name: Install cabal-install
112122
run: |
113-
"$HOME/.ghcup/bin/ghcup" install cabal 3.14.1.1-p1 || (cat "$HOME"/.ghcup/logs/*.* && false)
114-
echo "CABAL=$HOME/.ghcup/bin/cabal-3.14.1.1-p1 -vnormal+nowrap" >> "$GITHUB_ENV"
123+
"$HOME/.ghcup/bin/ghcup" install cabal 3.16.0.0 || (cat "$HOME"/.ghcup/logs/*.* && false)
124+
echo "CABAL=$HOME/.ghcup/bin/cabal-3.16.0.0 -vnormal+nowrap" >> "$GITHUB_ENV"
115125
- name: Install GHC (GHCup)
116126
if: matrix.setup-method == 'ghcup'
117127
run: |
@@ -187,7 +197,7 @@ jobs:
187197
chmod a+x $HOME/.cabal/bin/cabal-plan
188198
cabal-plan --version
189199
- name: checkout
190-
uses: actions/checkout@v4
200+
uses: actions/checkout@v7
191201
with:
192202
path: source
193203
- name: initial cabal.project for sdist
@@ -212,7 +222,11 @@ jobs:
212222
touch cabal.project.local
213223
echo "packages: ${PKGDIR_haskeline}" >> cabal.project
214224
if [ $((HCNUMVER >= 80200)) -ne 0 ] ; then echo "package haskeline" >> cabal.project ; fi
215-
if [ $((HCNUMVER >= 80200)) -ne 0 ] ; then echo " ghc-options: -Werror=missing-methods" >> cabal.project ; fi
225+
if [ $((HCNUMVER >= 80200)) -ne 0 ] ; then echo " ghc-options: -Werror=missing-methods -Werror=missing-fields" >> cabal.project ; fi
226+
if [ $((HCNUMVER >= 90400)) -ne 0 ] ; then echo "package haskeline" >> cabal.project ; fi
227+
if [ $((HCNUMVER >= 90400)) -ne 0 ] ; then echo " ghc-options: -Werror=unused-packages" >> cabal.project ; fi
228+
if [ $((HCNUMVER >= 90000)) -ne 0 ] ; then echo "package haskeline" >> cabal.project ; fi
229+
if [ $((HCNUMVER >= 90000)) -ne 0 ] ; then echo " ghc-options: -Werror=incomplete-patterns -Werror=incomplete-uni-patterns" >> cabal.project ; fi
216230
cat >> cabal.project <<EOF
217231
EOF
218232
$HCPKG list --simple-output --names-only | perl -ne 'for (split /\s+/) { print "constraints: any.$_ installed\n" unless /^(haskeline)$/; }' >> cabal.project.local
@@ -223,7 +237,7 @@ jobs:
223237
$CABAL v2-build $ARG_COMPILER $ARG_TESTS $ARG_BENCH --dry-run all
224238
cabal-plan
225239
- name: restore cache
226-
uses: actions/cache/restore@v4
240+
uses: actions/cache/restore@v6
227241
with:
228242
key: ${{ runner.os }}-${{ matrix.compiler }}-${{ github.sha }}
229243
path: ~/.cabal/store
@@ -254,7 +268,7 @@ jobs:
254268
$CABAL v2-build $ARG_COMPILER --disable-tests --disable-benchmarks all
255269
- name: save cache
256270
if: always()
257-
uses: actions/cache/save@v4
271+
uses: actions/cache/save@v6
258272
with:
259273
key: ${{ runner.os }}-${{ matrix.compiler }}-${{ github.sha }}
260274
path: ~/.cabal/store

haskeline.cabal

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,10 @@ Stability: Stable
2121
Build-Type: Simple
2222

2323
tested-with:
24-
GHC == 9.12.1
25-
GHC == 9.10.1
26-
GHC == 9.8.2
24+
GHC == 9.14.1
25+
GHC == 9.12.4
26+
GHC == 9.10.3
27+
GHC == 9.8.4
2728
GHC == 9.6.5
2829
GHC == 9.4.8
2930
GHC == 9.2.8
@@ -69,7 +70,6 @@ Library
6970
, bytestring >= 0.9 && < 0.13
7071
, filepath >= 1.2 && < 1.6
7172
, transformers >= 0.2 && < 0.7
72-
, process >= 1.0 && < 1.7
7373
, stm >= 2.4 && < 2.6
7474
, exceptions == 0.10.*
7575
Default-Language: Haskell98
@@ -113,7 +113,7 @@ Library
113113
c-sources: cbits/h_wcwidth.c
114114

115115
if os(windows)
116-
Build-depends: Win32 >= 2.1 && < 2.10 || >= 2.12
116+
Build-depends: Win32 >= 2.1 && < 2.10 || >= 2.12 && < 3
117117
Other-modules: System.Console.Haskeline.Backend.Win32
118118
System.Console.Haskeline.Backend.Win32.Echo
119119
c-sources: cbits/win_console.c
@@ -152,7 +152,6 @@ test-suite haskeline-tests
152152
Build-depends:
153153
-- shared dependencies with library
154154
base >= 4.9 && < 4.23
155-
, containers >= 0.4 && < 0.9
156155
, bytestring >= 0.9 && < 0.13
157156
, directory
158157
, process >= 1.0 && < 1.7
@@ -169,7 +168,7 @@ Executable haskeline-examples-Test
169168
if !flag(examples) {
170169
buildable: False
171170
}
172-
Build-depends: base, containers, haskeline, optparse-applicative
171+
Build-depends: base, haskeline, optparse-applicative < 1
173172
Default-Language: Haskell2010
174173
hs-source-dirs: examples
175174
Main-Is: Test.hs

0 commit comments

Comments
 (0)