Skip to content

Commit 88a7a9f

Browse files
committed
Support GHC-9.12
1 parent e4d2f12 commit 88a7a9f

2 files changed

Lines changed: 37 additions & 29 deletions

File tree

.github/workflows/haskell-ci.yml

Lines changed: 30 additions & 24 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.20240512
11+
# version: 0.19.20241220
1212
#
13-
# REGENDATA ("0.19.20240512",["github","cabal.project"])
13+
# REGENDATA ("0.19.20241220",["github","cabal.project"])
1414
#
1515
name: Haskell-CI
1616
on:
@@ -32,24 +32,24 @@ jobs:
3232
strategy:
3333
matrix:
3434
include:
35-
- compiler: ghc-9.10.1
35+
- compiler: ghc-9.12.1
3636
compilerKind: ghc
37-
compilerVersion: 9.10.1
37+
compilerVersion: 9.12.1
3838
setup-method: ghcup
3939
allow-failure: false
40-
- compiler: ghc-9.8.2
40+
- compiler: ghc-9.10.1
4141
compilerKind: ghc
42-
compilerVersion: 9.8.2
42+
compilerVersion: 9.10.1
4343
setup-method: ghcup
4444
allow-failure: false
45-
- compiler: ghc-9.6.3
45+
- compiler: ghc-9.6.4
4646
compilerKind: ghc
47-
compilerVersion: 9.6.3
47+
compilerVersion: 9.6.4
4848
setup-method: ghcup
4949
allow-failure: false
50-
- compiler: ghc-9.4.7
50+
- compiler: ghc-9.4.8
5151
compilerKind: ghc
52-
compilerVersion: 9.4.7
52+
compilerVersion: 9.4.8
5353
setup-method: ghcup
5454
allow-failure: false
5555
- compiler: ghc-9.2.8
@@ -79,15 +79,30 @@ jobs:
7979
allow-failure: false
8080
fail-fast: false
8181
steps:
82-
- name: apt
82+
- name: apt-get install
8383
run: |
8484
apt-get update
8585
apt-get install -y --no-install-recommends gnupg ca-certificates dirmngr curl git software-properties-common libtinfo5
86+
- name: Install GHCup
87+
run: |
8688
mkdir -p "$HOME/.ghcup/bin"
87-
curl -sL https://downloads.haskell.org/ghcup/0.1.20.0/x86_64-linux-ghcup-0.1.20.0 > "$HOME/.ghcup/bin/ghcup"
89+
curl -sL https://downloads.haskell.org/ghcup/0.1.30.0/x86_64-linux-ghcup-0.1.30.0 > "$HOME/.ghcup/bin/ghcup"
8890
chmod a+x "$HOME/.ghcup/bin/ghcup"
91+
- name: Install cabal-install (prerelease)
92+
run: |
93+
"$HOME/.ghcup/bin/ghcup" config add-release-channel https://raw.githubusercontent.com/haskell/ghcup-metadata/master/ghcup-prereleases-0.0.8.yaml;
94+
"$HOME/.ghcup/bin/ghcup" install cabal 3.15.0.0.2024.10.3 || (cat "$HOME"/.ghcup/logs/*.* && false)
95+
echo "CABAL=$HOME/.ghcup/bin/cabal-3.15.0.0.2024.10.3 -vnormal+nowrap" >> "$GITHUB_ENV"
96+
- name: Install GHC (GHCup)
97+
if: matrix.setup-method == 'ghcup'
98+
run: |
8999
"$HOME/.ghcup/bin/ghcup" install ghc "$HCVER" || (cat "$HOME"/.ghcup/logs/*.* && false)
90-
"$HOME/.ghcup/bin/ghcup" install cabal 3.10.2.0 || (cat "$HOME"/.ghcup/logs/*.* && false)
100+
HC=$("$HOME/.ghcup/bin/ghcup" whereis ghc "$HCVER")
101+
HCPKG=$(echo "$HC" | sed 's#ghc$#ghc-pkg#')
102+
HADDOCK=$(echo "$HC" | sed 's#ghc$#haddock#')
103+
echo "HC=$HC" >> "$GITHUB_ENV"
104+
echo "HCPKG=$HCPKG" >> "$GITHUB_ENV"
105+
echo "HADDOCK=$HADDOCK" >> "$GITHUB_ENV"
91106
env:
92107
HCKIND: ${{ matrix.compilerKind }}
93108
HCNAME: ${{ matrix.compiler }}
@@ -98,21 +113,12 @@ jobs:
98113
echo "LANG=C.UTF-8" >> "$GITHUB_ENV"
99114
echo "CABAL_DIR=$HOME/.cabal" >> "$GITHUB_ENV"
100115
echo "CABAL_CONFIG=$HOME/.cabal/config" >> "$GITHUB_ENV"
101-
HCDIR=/opt/$HCKIND/$HCVER
102-
HC=$("$HOME/.ghcup/bin/ghcup" whereis ghc "$HCVER")
103-
HCPKG=$(echo "$HC" | sed 's#ghc$#ghc-pkg#')
104-
HADDOCK=$(echo "$HC" | sed 's#ghc$#haddock#')
105-
echo "HC=$HC" >> "$GITHUB_ENV"
106-
echo "HCPKG=$HCPKG" >> "$GITHUB_ENV"
107-
echo "HADDOCK=$HADDOCK" >> "$GITHUB_ENV"
108-
echo "CABAL=$HOME/.ghcup/bin/cabal-3.10.2.0 -vnormal+nowrap" >> "$GITHUB_ENV"
109116
HCNUMVER=$(${HC} --numeric-version|perl -ne '/^(\d+)\.(\d+)\.(\d+)(\.(\d+))?$/; print(10000 * $1 + 100 * $2 + ($3 == 0 ? $5 != 1 : $3))')
110117
echo "HCNUMVER=$HCNUMVER" >> "$GITHUB_ENV"
111118
echo "ARG_TESTS=--enable-tests" >> "$GITHUB_ENV"
112119
echo "ARG_BENCH=--enable-benchmarks" >> "$GITHUB_ENV"
113120
echo "HEADHACKAGE=false" >> "$GITHUB_ENV"
114121
echo "ARG_COMPILER=--$HCKIND --with-compiler=$HC" >> "$GITHUB_ENV"
115-
echo "GHCJSARITH=0" >> "$GITHUB_ENV"
116122
env:
117123
HCKIND: ${{ matrix.compilerKind }}
118124
HCNAME: ${{ matrix.compiler }}
@@ -190,7 +196,7 @@ jobs:
190196
echo " ghc-options: -Werror=missing-methods" >> cabal.project
191197
cat >> cabal.project <<EOF
192198
EOF
193-
$HCPKG list --simple-output --names-only | perl -ne 'for (split /\s+/) { print "constraints: $_ installed\n" unless /^(OneTuple)$/; }' >> cabal.project.local
199+
$HCPKG list --simple-output --names-only | perl -ne 'for (split /\s+/) { print "constraints: any.$_ installed\n" unless /^(OneTuple)$/; }' >> cabal.project.local
194200
cat cabal.project
195201
cat cabal.project.local
196202
- name: dump install plan
@@ -228,8 +234,8 @@ jobs:
228234
rm -f cabal.project.local
229235
$CABAL v2-build $ARG_COMPILER --disable-tests --disable-benchmarks all
230236
- name: save cache
231-
uses: actions/cache/save@v4
232237
if: always()
238+
uses: actions/cache/save@v4
233239
with:
234240
key: ${{ runner.os }}-${{ matrix.compiler }}-${{ github.sha }}
235241
path: ~/.cabal/store

OneTuple.cabal

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
cabal-version: 1.12
22
name: OneTuple
33
version: 0.4.2
4+
x-revision: 1
45
synopsis: Singleton Tuple
56
category: Data
67
description:
@@ -27,10 +28,11 @@ tested-with:
2728
|| ==8.10.7
2829
|| ==9.0.2
2930
|| ==9.2.8
30-
|| ==9.4.7
31-
|| ==9.6.3
32-
|| ==9.8.2
31+
|| ==9.4.8
32+
|| ==9.6.4
33+
|| ==9.8.6
3334
|| ==9.10.1
35+
|| ==9.12.1
3436

3537
extra-source-files: Changelog.md
3638

@@ -47,13 +49,13 @@ library
4749

4850
hs-source-dirs: src
4951
build-depends:
50-
base >=4.12 && <4.21
52+
base >=4.12 && <4.22
5153
, template-haskell
5254

5355
if impl(ghc >=9.0)
5456
build-depends: ghc-prim
5557
else
56-
build-depends: hashable >=1.3.5.0 && <1.5
58+
build-depends: hashable >=1.3.5.0 && <1.6
5759

5860
if !impl(ghc >=9.0)
5961
build-depends: foldable1-classes-compat >=0.1 && <0.2

0 commit comments

Comments
 (0)