88#
99# For more information, see https://github.com/haskell-CI/haskell-ci
1010#
11- # version: 0.17.20240109
11+ # version: 0.19.20241223
1212#
13- # REGENDATA ("0.17.20240109 ",["github","cabal.project"])
13+ # REGENDATA ("0.19.20241223 ",["github","cabal.project"])
1414#
1515name : Haskell-CI
1616on :
@@ -29,24 +29,29 @@ jobs:
2929 timeout-minutes :
3030 60
3131 container :
32- image : buildpack-deps:bionic
32+ image : buildpack-deps:jammy
3333 continue-on-error : ${{ matrix.allow-failure }}
3434 strategy :
3535 matrix :
3636 include :
37+ - compiler : ghc-9.12.1
38+ compilerKind : ghc
39+ compilerVersion : 9.12.1
40+ setup-method : ghcup
41+ allow-failure : false
3742 - compiler : ghc-9.10.1
3843 compilerKind : ghc
3944 compilerVersion : 9.10.1
4045 setup-method : ghcup
4146 allow-failure : false
42- - compiler : ghc-9.8.2
47+ - compiler : ghc-9.8.4
4348 compilerKind : ghc
44- compilerVersion : 9.8.2
49+ compilerVersion : 9.8.4
4550 setup-method : ghcup
4651 allow-failure : false
47- - compiler : ghc-9.6.5
52+ - compiler : ghc-9.6.6
4853 compilerKind : ghc
49- compilerVersion : 9.6.5
54+ compilerVersion : 9.6.6
5055 setup-method : ghcup
5156 allow-failure : false
5257 - compiler : ghc-9.4.8
@@ -72,81 +77,54 @@ jobs:
7277 - compiler : ghc-8.8.4
7378 compilerKind : ghc
7479 compilerVersion : 8.8.4
75- setup-method : hvr-ppa
80+ setup-method : ghcup
7681 allow-failure : false
7782 - compiler : ghc-8.6.5
7883 compilerKind : ghc
7984 compilerVersion : 8.6.5
80- setup-method : hvr-ppa
85+ setup-method : ghcup
8186 allow-failure : false
8287 - compiler : ghc-8.4.4
8388 compilerKind : ghc
8489 compilerVersion : 8.4.4
85- setup-method : hvr-ppa
90+ setup-method : ghcup
8691 allow-failure : false
8792 - compiler : ghc-8.2.2
8893 compilerKind : ghc
8994 compilerVersion : 8.2.2
90- setup-method : hvr-ppa
95+ setup-method : ghcup
9196 allow-failure : false
9297 - compiler : ghc-8.0.2
9398 compilerKind : ghc
9499 compilerVersion : 8.0.2
95- setup-method : hvr-ppa
96- allow-failure : false
97- - compiler : ghc-7.10.3
98- compilerKind : ghc
99- compilerVersion : 7.10.3
100- setup-method : hvr-ppa
101- allow-failure : false
102- - compiler : ghc-7.8.4
103- compilerKind : ghc
104- compilerVersion : 7.8.4
105- setup-method : hvr-ppa
106- allow-failure : false
107- - compiler : ghc-7.6.3
108- compilerKind : ghc
109- compilerVersion : 7.6.3
110- setup-method : hvr-ppa
111- allow-failure : false
112- - compiler : ghc-7.4.2
113- compilerKind : ghc
114- compilerVersion : 7.4.2
115- setup-method : hvr-ppa
116- allow-failure : false
117- - compiler : ghc-7.2.2
118- compilerKind : ghc
119- compilerVersion : 7.2.2
120- setup-method : hvr-ppa
121- allow-failure : false
122- - compiler : ghc-7.0.4
123- compilerKind : ghc
124- compilerVersion : 7.0.4
125- setup-method : hvr-ppa
100+ setup-method : ghcup
126101 allow-failure : false
127102 fail-fast : false
128103 steps :
129- - name : apt
104+ - name : apt-get install
130105 run : |
131106 apt-get update
132- apt-get install -y --no-install-recommends gnupg ca-certificates dirmngr curl git software-properties-common libtinfo5
133- if [ "${{ matrix.setup-method }}" = ghcup ]; then
134- mkdir -p "$HOME/.ghcup/bin"
135- curl -sL https://downloads.haskell.org/ghcup/0.1.20.0/x86_64-linux-ghcup-0.1.20.0 > "$HOME/.ghcup/bin/ghcup"
136- chmod a+x "$HOME/.ghcup/bin/ghcup"
137- "$HOME/.ghcup/bin/ghcup" install ghc "$HCVER" || (cat "$HOME"/.ghcup/logs/*.* && false)
138- "$HOME/.ghcup/bin/ghcup" install cabal 3.10.2.0 || (cat "$HOME"/.ghcup/logs/*.* && false)
139- apt-get update
140- apt-get install -y libxml2-dev
141- else
142- apt-add-repository -y 'ppa:hvr/ghc'
143- apt-get update
144- apt-get install -y "$HCNAME" libxml2-dev
145- mkdir -p "$HOME/.ghcup/bin"
146- curl -sL https://downloads.haskell.org/ghcup/0.1.20.0/x86_64-linux-ghcup-0.1.20.0 > "$HOME/.ghcup/bin/ghcup"
147- chmod a+x "$HOME/.ghcup/bin/ghcup"
148- "$HOME/.ghcup/bin/ghcup" install cabal 3.10.2.0 || (cat "$HOME"/.ghcup/logs/*.* && false)
149- fi
107+ apt-get install -y --no-install-recommends gnupg ca-certificates dirmngr curl git software-properties-common libtinfo5 libnuma-dev
108+ apt-get install -y libxml2-dev
109+ - name : Install GHCup
110+ run : |
111+ mkdir -p "$HOME/.ghcup/bin"
112+ curl -sL https://downloads.haskell.org/ghcup/0.1.30.0/x86_64-linux-ghcup-0.1.30.0 > "$HOME/.ghcup/bin/ghcup"
113+ chmod a+x "$HOME/.ghcup/bin/ghcup"
114+ - name : Install cabal-install
115+ run : |
116+ "$HOME/.ghcup/bin/ghcup" install cabal 3.14.1.0 || (cat "$HOME"/.ghcup/logs/*.* && false)
117+ echo "CABAL=$HOME/.ghcup/bin/cabal-3.14.1.0 -vnormal+nowrap" >> "$GITHUB_ENV"
118+ - name : Install GHC (GHCup)
119+ if : matrix.setup-method == 'ghcup'
120+ run : |
121+ "$HOME/.ghcup/bin/ghcup" install ghc "$HCVER" || (cat "$HOME"/.ghcup/logs/*.* && false)
122+ HC=$("$HOME/.ghcup/bin/ghcup" whereis ghc "$HCVER")
123+ HCPKG=$(echo "$HC" | sed 's#ghc$#ghc-pkg#')
124+ HADDOCK=$(echo "$HC" | sed 's#ghc$#haddock#')
125+ echo "HC=$HC" >> "$GITHUB_ENV"
126+ echo "HCPKG=$HCPKG" >> "$GITHUB_ENV"
127+ echo "HADDOCK=$HADDOCK" >> "$GITHUB_ENV"
150128 env :
151129 HCKIND : ${{ matrix.compilerKind }}
152130 HCNAME : ${{ matrix.compiler }}
@@ -157,30 +135,12 @@ jobs:
157135 echo "LANG=C.UTF-8" >> "$GITHUB_ENV"
158136 echo "CABAL_DIR=$HOME/.cabal" >> "$GITHUB_ENV"
159137 echo "CABAL_CONFIG=$HOME/.cabal/config" >> "$GITHUB_ENV"
160- HCDIR=/opt/$HCKIND/$HCVER
161- if [ "${{ matrix.setup-method }}" = ghcup ]; then
162- HC=$("$HOME/.ghcup/bin/ghcup" whereis ghc "$HCVER")
163- HCPKG=$(echo "$HC" | sed 's#ghc$#ghc-pkg#')
164- HADDOCK=$(echo "$HC" | sed 's#ghc$#haddock#')
165- echo "HC=$HC" >> "$GITHUB_ENV"
166- echo "HCPKG=$HCPKG" >> "$GITHUB_ENV"
167- echo "HADDOCK=$HADDOCK" >> "$GITHUB_ENV"
168- echo "CABAL=$HOME/.ghcup/bin/cabal-3.10.2.0 -vnormal+nowrap" >> "$GITHUB_ENV"
169- else
170- HC=$HCDIR/bin/$HCKIND
171- echo "HC=$HC" >> "$GITHUB_ENV"
172- echo "HCPKG=$HCDIR/bin/$HCKIND-pkg" >> "$GITHUB_ENV"
173- echo "HADDOCK=$HCDIR/bin/haddock" >> "$GITHUB_ENV"
174- echo "CABAL=$HOME/.ghcup/bin/cabal-3.10.2.0 -vnormal+nowrap" >> "$GITHUB_ENV"
175- fi
176-
177138 HCNUMVER=$(${HC} --numeric-version|perl -ne '/^(\d+)\.(\d+)\.(\d+)(\.(\d+))?$/; print(10000 * $1 + 100 * $2 + ($3 == 0 ? $5 != 1 : $3))')
178139 echo "HCNUMVER=$HCNUMVER" >> "$GITHUB_ENV"
179140 echo "ARG_TESTS=--enable-tests" >> "$GITHUB_ENV"
180141 echo "ARG_BENCH=--enable-benchmarks" >> "$GITHUB_ENV"
181142 echo "HEADHACKAGE=false" >> "$GITHUB_ENV"
182143 echo "ARG_COMPILER=--$HCKIND --with-compiler=$HC" >> "$GITHUB_ENV"
183- echo "GHCJSARITH=0" >> "$GITHUB_ENV"
184144 env :
185145 HCKIND : ${{ matrix.compilerKind }}
186146 HCNAME : ${{ matrix.compiler }}
@@ -230,7 +190,7 @@ jobs:
230190 chmod a+x $HOME/.cabal/bin/cabal-plan
231191 cabal-plan --version
232192 - name : checkout
233- uses : actions/checkout@v3
193+ uses : actions/checkout@v4
234194 with :
235195 path : source
236196 - name : initial cabal.project for sdist
@@ -278,15 +238,15 @@ jobs:
278238 package libxml
279239 extra-include-dirs: /usr/include/libxml2
280240 EOF
281- $HCPKG list --simple-output --names-only | perl -ne 'for (split /\s+/) { print "constraints: $_ installed\n" unless /^(test-framework|test-framework-example|test-framework-hunit|test-framework-quickcheck2)$/; }' >> cabal.project.local
241+ $HCPKG list --simple-output --names-only | perl -ne 'for (split /\s+/) { print "constraints: any. $_ installed\n" unless /^(test-framework|test-framework-example|test-framework-hunit|test-framework-quickcheck2)$/; }' >> cabal.project.local
282242 cat cabal.project
283243 cat cabal.project.local
284244 - name : dump install plan
285245 run : |
286246 $CABAL v2-build $ARG_COMPILER $ARG_TESTS $ARG_BENCH --dry-run all
287247 cabal-plan
288248 - name : restore cache
289- uses : actions/cache/restore@v3
249+ uses : actions/cache/restore@v4
290250 with :
291251 key : ${{ runner.os }}-${{ matrix.compiler }}-${{ github.sha }}
292252 path : ~/.cabal/store
@@ -322,8 +282,8 @@ jobs:
322282 rm -f cabal.project.local
323283 $CABAL v2-build $ARG_COMPILER --disable-tests --disable-benchmarks all
324284 - name : save cache
325- uses : actions/cache/save@v3
326285 if : always()
286+ uses : actions/cache/save@v4
327287 with :
328288 key : ${{ runner.os }}-${{ matrix.compiler }}-${{ github.sha }}
329289 path : ~/.cabal/store
0 commit comments