Skip to content

Commit 163b35a

Browse files
committed
Regenerate CI.
Sadly this involves dropping some ancient GHC versions (which are no longer supported by haskell-ci). Realistically, this means that they will probably stop working for future versions of fgl, as they will no longer be tested.
1 parent 93eedd6 commit 163b35a

File tree

2 files changed

+25
-70
lines changed

2 files changed

+25
-70
lines changed

.github/workflows/haskell-ci.yml

Lines changed: 24 additions & 68 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.17.20231010
11+
# version: 0.19.20240708
1212
#
13-
# REGENDATA ("0.17.20231010",["github","fgl.cabal"])
13+
# REGENDATA ("0.19.20240708",["github","fgl.cabal"])
1414
#
1515
name: Haskell-CI
1616
on:
@@ -23,7 +23,7 @@ jobs:
2323
timeout-minutes:
2424
60
2525
container:
26-
image: buildpack-deps:bionic
26+
image: buildpack-deps:jammy
2727
continue-on-error: ${{ matrix.allow-failure }}
2828
strategy:
2929
matrix:
@@ -61,74 +61,39 @@ jobs:
6161
- compiler: ghc-8.8.2
6262
compilerKind: ghc
6363
compilerVersion: 8.8.2
64-
setup-method: hvr-ppa
64+
setup-method: ghcup
6565
allow-failure: false
6666
- compiler: ghc-8.6.2
6767
compilerKind: ghc
6868
compilerVersion: 8.6.2
69-
setup-method: hvr-ppa
69+
setup-method: ghcup
7070
allow-failure: false
7171
- compiler: ghc-8.4.3
7272
compilerKind: ghc
7373
compilerVersion: 8.4.3
74-
setup-method: hvr-ppa
74+
setup-method: ghcup
7575
allow-failure: false
7676
- compiler: ghc-8.2.2
7777
compilerKind: ghc
7878
compilerVersion: 8.2.2
79-
setup-method: hvr-ppa
79+
setup-method: ghcup
8080
allow-failure: false
8181
- compiler: ghc-8.0.2
8282
compilerKind: ghc
8383
compilerVersion: 8.0.2
84-
setup-method: hvr-ppa
85-
allow-failure: false
86-
- compiler: ghc-7.10.3
87-
compilerKind: ghc
88-
compilerVersion: 7.10.3
89-
setup-method: hvr-ppa
90-
allow-failure: false
91-
- compiler: ghc-7.8.4
92-
compilerKind: ghc
93-
compilerVersion: 7.8.4
94-
setup-method: hvr-ppa
95-
allow-failure: false
96-
- compiler: ghc-7.6.3
97-
compilerKind: ghc
98-
compilerVersion: 7.6.3
99-
setup-method: hvr-ppa
100-
allow-failure: false
101-
- compiler: ghc-7.4.2
102-
compilerKind: ghc
103-
compilerVersion: 7.4.2
104-
setup-method: hvr-ppa
105-
allow-failure: false
106-
- compiler: ghc-7.2.2
107-
compilerKind: ghc
108-
compilerVersion: 7.2.2
109-
setup-method: hvr-ppa
84+
setup-method: ghcup
11085
allow-failure: false
11186
fail-fast: false
11287
steps:
11388
- name: apt
11489
run: |
11590
apt-get update
11691
apt-get install -y --no-install-recommends gnupg ca-certificates dirmngr curl git software-properties-common libtinfo5
117-
if [ "${{ matrix.setup-method }}" = ghcup ]; then
118-
mkdir -p "$HOME/.ghcup/bin"
119-
curl -sL https://downloads.haskell.org/ghcup/0.1.19.5/x86_64-linux-ghcup-0.1.19.5 > "$HOME/.ghcup/bin/ghcup"
120-
chmod a+x "$HOME/.ghcup/bin/ghcup"
121-
"$HOME/.ghcup/bin/ghcup" install ghc "$HCVER" || (cat "$HOME"/.ghcup/logs/*.* && false)
122-
"$HOME/.ghcup/bin/ghcup" install cabal 3.10.1.0 || (cat "$HOME"/.ghcup/logs/*.* && false)
123-
else
124-
apt-add-repository -y 'ppa:hvr/ghc'
125-
apt-get update
126-
apt-get install -y "$HCNAME"
127-
mkdir -p "$HOME/.ghcup/bin"
128-
curl -sL https://downloads.haskell.org/ghcup/0.1.19.5/x86_64-linux-ghcup-0.1.19.5 > "$HOME/.ghcup/bin/ghcup"
129-
chmod a+x "$HOME/.ghcup/bin/ghcup"
130-
"$HOME/.ghcup/bin/ghcup" install cabal 3.10.1.0 || (cat "$HOME"/.ghcup/logs/*.* && false)
131-
fi
92+
mkdir -p "$HOME/.ghcup/bin"
93+
curl -sL https://downloads.haskell.org/ghcup/0.1.30.0/x86_64-linux-ghcup-0.1.30.0 > "$HOME/.ghcup/bin/ghcup"
94+
chmod a+x "$HOME/.ghcup/bin/ghcup"
95+
"$HOME/.ghcup/bin/ghcup" install ghc "$HCVER" || (cat "$HOME"/.ghcup/logs/*.* && false)
96+
"$HOME/.ghcup/bin/ghcup" install cabal 3.12.1.0 || (cat "$HOME"/.ghcup/logs/*.* && false)
13297
env:
13398
HCKIND: ${{ matrix.compilerKind }}
13499
HCNAME: ${{ matrix.compiler }}
@@ -140,22 +105,13 @@ jobs:
140105
echo "CABAL_DIR=$HOME/.cabal" >> "$GITHUB_ENV"
141106
echo "CABAL_CONFIG=$HOME/.cabal/config" >> "$GITHUB_ENV"
142107
HCDIR=/opt/$HCKIND/$HCVER
143-
if [ "${{ matrix.setup-method }}" = ghcup ]; then
144-
HC=$("$HOME/.ghcup/bin/ghcup" whereis ghc "$HCVER")
145-
HCPKG=$(echo "$HC" | sed 's#ghc$#ghc-pkg#')
146-
HADDOCK=$(echo "$HC" | sed 's#ghc$#haddock#')
147-
echo "HC=$HC" >> "$GITHUB_ENV"
148-
echo "HCPKG=$HCPKG" >> "$GITHUB_ENV"
149-
echo "HADDOCK=$HADDOCK" >> "$GITHUB_ENV"
150-
echo "CABAL=$HOME/.ghcup/bin/cabal-3.10.1.0 -vnormal+nowrap" >> "$GITHUB_ENV"
151-
else
152-
HC=$HCDIR/bin/$HCKIND
153-
echo "HC=$HC" >> "$GITHUB_ENV"
154-
echo "HCPKG=$HCDIR/bin/$HCKIND-pkg" >> "$GITHUB_ENV"
155-
echo "HADDOCK=$HCDIR/bin/haddock" >> "$GITHUB_ENV"
156-
echo "CABAL=$HOME/.ghcup/bin/cabal-3.10.1.0 -vnormal+nowrap" >> "$GITHUB_ENV"
157-
fi
158-
108+
HC=$("$HOME/.ghcup/bin/ghcup" whereis ghc "$HCVER")
109+
HCPKG=$(echo "$HC" | sed 's#ghc$#ghc-pkg#')
110+
HADDOCK=$(echo "$HC" | sed 's#ghc$#haddock#')
111+
echo "HC=$HC" >> "$GITHUB_ENV"
112+
echo "HCPKG=$HCPKG" >> "$GITHUB_ENV"
113+
echo "HADDOCK=$HADDOCK" >> "$GITHUB_ENV"
114+
echo "CABAL=$HOME/.ghcup/bin/cabal-3.12.1.0 -vnormal+nowrap" >> "$GITHUB_ENV"
159115
HCNUMVER=$(${HC} --numeric-version|perl -ne '/^(\d+)\.(\d+)\.(\d+)(\.(\d+))?$/; print(10000 * $1 + 100 * $2 + ($3 == 0 ? $5 != 1 : $3))')
160116
echo "HCNUMVER=$HCNUMVER" >> "$GITHUB_ENV"
161117
echo "ARG_TESTS=--enable-tests" >> "$GITHUB_ENV"
@@ -212,7 +168,7 @@ jobs:
212168
chmod a+x $HOME/.cabal/bin/cabal-plan
213169
cabal-plan --version
214170
- name: checkout
215-
uses: actions/checkout@v3
171+
uses: actions/checkout@v4
216172
with:
217173
path: source
218174
- name: initial cabal.project for sdist
@@ -240,15 +196,15 @@ jobs:
240196
if [ $((HCNUMVER >= 80200)) -ne 0 ] ; then echo " ghc-options: -Werror=missing-methods" >> cabal.project ; fi
241197
cat >> cabal.project <<EOF
242198
EOF
243-
$HCPKG list --simple-output --names-only | perl -ne 'for (split /\s+/) { print "constraints: $_ installed\n" unless /^(fgl)$/; }' >> cabal.project.local
199+
$HCPKG list --simple-output --names-only | perl -ne 'for (split /\s+/) { print "constraints: any.$_ installed\n" unless /^(fgl)$/; }' >> cabal.project.local
244200
cat cabal.project
245201
cat cabal.project.local
246202
- name: dump install plan
247203
run: |
248204
$CABAL v2-build $ARG_COMPILER $ARG_TESTS $ARG_BENCH --dry-run all
249205
cabal-plan
250206
- name: restore cache
251-
uses: actions/cache/restore@v3
207+
uses: actions/cache/restore@v4
252208
with:
253209
key: ${{ runner.os }}-${{ matrix.compiler }}-${{ github.sha }}
254210
path: ~/.cabal/store
@@ -278,7 +234,7 @@ jobs:
278234
rm -f cabal.project.local
279235
$CABAL v2-build $ARG_COMPILER --disable-tests --disable-benchmarks all
280236
- name: save cache
281-
uses: actions/cache/save@v3
237+
uses: actions/cache/save@v4
282238
if: always()
283239
with:
284240
key: ${{ runner.os }}-${{ matrix.compiler }}-${{ github.sha }}

fgl.cabal

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,7 @@ build-type: Simple
1717
extra-source-files:
1818
ChangeLog
1919

20-
tested-with: GHC == 7.2.2, GHC == 7.4.2, GHC == 7.6.3, GHC == 7.8.4,
21-
GHC == 7.10.3, GHC == 8.0.2, GHC == 8.2.2, GHC == 8.4.3,
20+
tested-with: GHC == 8.0.2, GHC == 8.2.2, GHC == 8.4.3,
2221
GHC == 8.6.2, GHC == 8.8.2, GHC == 8.10.7, GHC == 9.0.2,
2322
GHC == 9.2.4, GHC == 9.4.4, GHC == 9.6.3, GHC == 9.8.1
2423

0 commit comments

Comments
 (0)