Skip to content

Commit 6af2a2b

Browse files
committed
Update CI to GHC 9.2.1, 9.0.2 and 8.10.7
Also: - remove .travis.yml
1 parent 2ab19dc commit 6af2a2b

File tree

3 files changed

+60
-55
lines changed

3 files changed

+60
-55
lines changed

.github/workflows/haskell-ci.yml

Lines changed: 48 additions & 16 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.13.20210606
11+
# version: 0.14.1
1212
#
13-
# REGENDATA ("0.13.20210606",["github","alex.cabal"])
13+
# REGENDATA ("0.14.1",["github","alex.cabal"])
1414
#
1515
name: Haskell-CI
1616
on:
@@ -20,21 +20,28 @@ jobs:
2020
linux:
2121
name: Haskell-CI - Linux - ${{ matrix.compiler }}
2222
runs-on: ubuntu-18.04
23+
timeout-minutes:
24+
60
2325
container:
2426
image: buildpack-deps:bionic
2527
continue-on-error: ${{ matrix.allow-failure }}
2628
strategy:
2729
matrix:
2830
include:
29-
- compiler: ghc-9.0.1
31+
- compiler: ghc-9.2.1
3032
compilerKind: ghc
31-
compilerVersion: 9.0.1
32-
setup-method: hvr-ppa
33+
compilerVersion: 9.2.1
34+
setup-method: ghcup
3335
allow-failure: false
34-
- compiler: ghc-8.10.4
36+
- compiler: ghc-9.0.2
3537
compilerKind: ghc
36-
compilerVersion: 8.10.4
37-
setup-method: hvr-ppa
38+
compilerVersion: 9.0.2
39+
setup-method: ghcup
40+
allow-failure: false
41+
- compiler: ghc-8.10.7
42+
compilerKind: ghc
43+
compilerVersion: 8.10.7
44+
setup-method: ghcup
3845
allow-failure: false
3946
- compiler: ghc-8.8.4
4047
compilerKind: ghc
@@ -92,9 +99,21 @@ jobs:
9299
run: |
93100
apt-get update
94101
apt-get install -y --no-install-recommends gnupg ca-certificates dirmngr curl git software-properties-common libtinfo5
95-
apt-add-repository -y 'ppa:hvr/ghc'
96-
apt-get update
97-
apt-get install -y "$HCNAME" cabal-install-3.4
102+
if [ "${{ matrix.setup-method }}" = ghcup ]; then
103+
mkdir -p "$HOME/.ghcup/bin"
104+
curl -sL https://downloads.haskell.org/ghcup/0.1.17.3/x86_64-linux-ghcup-0.1.17.3 > "$HOME/.ghcup/bin/ghcup"
105+
chmod a+x "$HOME/.ghcup/bin/ghcup"
106+
"$HOME/.ghcup/bin/ghcup" install ghc "$HCVER"
107+
"$HOME/.ghcup/bin/ghcup" install cabal 3.6.2.0
108+
else
109+
apt-add-repository -y 'ppa:hvr/ghc'
110+
apt-get update
111+
apt-get install -y "$HCNAME"
112+
mkdir -p "$HOME/.ghcup/bin"
113+
curl -sL https://downloads.haskell.org/ghcup/0.1.17.3/x86_64-linux-ghcup-0.1.17.3 > "$HOME/.ghcup/bin/ghcup"
114+
chmod a+x "$HOME/.ghcup/bin/ghcup"
115+
"$HOME/.ghcup/bin/ghcup" install cabal 3.6.2.0
116+
fi
98117
env:
99118
HCKIND: ${{ matrix.compilerKind }}
100119
HCNAME: ${{ matrix.compiler }}
@@ -106,11 +125,20 @@ jobs:
106125
echo "CABAL_DIR=$HOME/.cabal" >> "$GITHUB_ENV"
107126
echo "CABAL_CONFIG=$HOME/.cabal/config" >> "$GITHUB_ENV"
108127
HCDIR=/opt/$HCKIND/$HCVER
109-
HC=$HCDIR/bin/$HCKIND
110-
echo "HC=$HC" >> "$GITHUB_ENV"
111-
echo "HCPKG=$HCDIR/bin/$HCKIND-pkg" >> "$GITHUB_ENV"
112-
echo "HADDOCK=$HCDIR/bin/haddock" >> "$GITHUB_ENV"
113-
echo "CABAL=/opt/cabal/3.4/bin/cabal -vnormal+nowrap" >> "$GITHUB_ENV"
128+
if [ "${{ matrix.setup-method }}" = ghcup ]; then
129+
HC=$HOME/.ghcup/bin/$HCKIND-$HCVER
130+
echo "HC=$HC" >> "$GITHUB_ENV"
131+
echo "HCPKG=$HOME/.ghcup/bin/$HCKIND-pkg-$HCVER" >> "$GITHUB_ENV"
132+
echo "HADDOCK=$HOME/.ghcup/bin/haddock-$HCVER" >> "$GITHUB_ENV"
133+
echo "CABAL=$HOME/.ghcup/bin/cabal-3.6.2.0 -vnormal+nowrap" >> "$GITHUB_ENV"
134+
else
135+
HC=$HCDIR/bin/$HCKIND
136+
echo "HC=$HC" >> "$GITHUB_ENV"
137+
echo "HCPKG=$HCDIR/bin/$HCKIND-pkg" >> "$GITHUB_ENV"
138+
echo "HADDOCK=$HCDIR/bin/haddock" >> "$GITHUB_ENV"
139+
echo "CABAL=$HOME/.ghcup/bin/cabal-3.6.2.0 -vnormal+nowrap" >> "$GITHUB_ENV"
140+
fi
141+
114142
HCNUMVER=$(${HC} --numeric-version|perl -ne '/^(\d+)\.(\d+)\.(\d+)(\.(\d+))?$/; print(10000 * $1 + 100 * $2 + ($3 == 0 ? $5 != 1 : $3))')
115143
echo "HCNUMVER=$HCNUMVER" >> "$GITHUB_ENV"
116144
echo "ARG_TESTS=--enable-tests" >> "$GITHUB_ENV"
@@ -144,6 +172,10 @@ jobs:
144172
repository hackage.haskell.org
145173
url: http://hackage.haskell.org/
146174
EOF
175+
cat >> $CABAL_CONFIG <<EOF
176+
program-default-options
177+
ghc-options: $GHCJOBS +RTS -M3G -RTS
178+
EOF
147179
cat $CABAL_CONFIG
148180
- name: versions
149181
run: |

.travis.yml

Lines changed: 0 additions & 28 deletions
This file was deleted.

alex.cabal

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -22,18 +22,19 @@ category: Development
2222
build-type: Simple
2323

2424
tested-with:
25-
GHC == 7.0.4
26-
GHC == 7.4.2
27-
GHC == 7.6.3
28-
GHC == 7.8.4
29-
GHC == 7.10.3
30-
GHC == 8.0.2
31-
GHC == 8.2.2
32-
GHC == 8.4.4
33-
GHC == 8.6.5
25+
GHC == 9.2.1
26+
GHC == 9.0.2
27+
GHC == 8.10.7
3428
GHC == 8.8.4
35-
GHC == 8.10.4
36-
GHC == 9.0.1
29+
GHC == 8.6.5
30+
GHC == 8.4.4
31+
GHC == 8.2.2
32+
GHC == 8.0.2
33+
GHC == 7.10.3
34+
GHC == 7.8.4
35+
GHC == 7.6.3
36+
GHC == 7.4.2
37+
GHC == 7.0.4
3738

3839
data-dir: data/
3940

0 commit comments

Comments
 (0)