Skip to content

Commit 1d1cad7

Browse files
committed
haskell-ci-0.12, update CONTRIBUTING
1 parent 0e463d9 commit 1d1cad7

File tree

2 files changed

+36
-27
lines changed

2 files changed

+36
-27
lines changed

.github/workflows/haskell-ci.yml

Lines changed: 35 additions & 26 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.11.20210101
11+
# version: 0.12
1212
#
13-
# REGENDATA ("0.11.20210101",["github","postgresql-libpq.cabal"])
13+
# REGENDATA ("0.12",["github","postgresql-libpq.cabal"])
1414
#
1515
name: Haskell-CI
1616
on:
@@ -22,7 +22,7 @@ on:
2222
- master
2323
jobs:
2424
linux:
25-
name: Haskell-CI Linux - GHC ${{ matrix.ghc }}
25+
name: Haskell-CI - Linux - ${{ matrix.compiler }}
2626
runs-on: ubuntu-18.04
2727
container:
2828
image: buildpack-deps:bionic
@@ -36,29 +36,31 @@ jobs:
3636
strategy:
3737
matrix:
3838
include:
39-
- ghc: 8.10.3
39+
- compiler: ghc-9.0.1
4040
allow-failure: false
41-
- ghc: 8.8.4
41+
- compiler: ghc-8.10.4
4242
allow-failure: false
43-
- ghc: 8.6.5
43+
- compiler: ghc-8.8.4
4444
allow-failure: false
45-
- ghc: 8.4.4
45+
- compiler: ghc-8.6.5
4646
allow-failure: false
47-
- ghc: 8.2.2
47+
- compiler: ghc-8.4.4
4848
allow-failure: false
49-
- ghc: 8.0.2
49+
- compiler: ghc-8.2.2
5050
allow-failure: false
51-
- ghc: 7.10.3
51+
- compiler: ghc-8.0.2
5252
allow-failure: false
53-
- ghc: 7.8.4
53+
- compiler: ghc-7.10.3
5454
allow-failure: false
55-
- ghc: 7.6.3
55+
- compiler: ghc-7.8.4
5656
allow-failure: false
57-
- ghc: 7.4.2
57+
- compiler: ghc-7.6.3
5858
allow-failure: false
59-
- ghc: 7.2.2
59+
- compiler: ghc-7.4.2
6060
allow-failure: false
61-
- ghc: 7.0.4
61+
- compiler: ghc-7.2.2
62+
allow-failure: false
63+
- compiler: ghc-7.0.4
6264
allow-failure: false
6365
fail-fast: false
6466
steps:
@@ -68,28 +70,31 @@ jobs:
6870
apt-get install -y --no-install-recommends gnupg ca-certificates dirmngr curl git software-properties-common
6971
apt-add-repository -y 'ppa:hvr/ghc'
7072
apt-get update
71-
apt-get install -y ghc-$GHC_VERSION cabal-install-3.2
73+
apt-get install -y $CC cabal-install-3.4
7274
env:
73-
GHC_VERSION: ${{ matrix.ghc }}
75+
CC: ${{ matrix.compiler }}
7476
- name: Set PATH and environment variables
7577
run: |
7678
echo "$HOME/.cabal/bin" >> $GITHUB_PATH
7779
echo "LANG=C.UTF-8" >> $GITHUB_ENV
7880
echo "CABAL_DIR=$HOME/.cabal" >> $GITHUB_ENV
7981
echo "CABAL_CONFIG=$HOME/.cabal/config" >> $GITHUB_ENV
80-
HC=/opt/ghc/$GHC_VERSION/bin/ghc
82+
HCDIR=$(echo "/opt/$CC" | sed 's/-/\//')
83+
HCNAME=ghc
84+
HC=$HCDIR/bin/$HCNAME
8185
echo "HC=$HC" >> $GITHUB_ENV
82-
echo "HCPKG=/opt/ghc/$GHC_VERSION/bin/ghc-pkg" >> $GITHUB_ENV
83-
echo "HADDOCK=/opt/ghc/$GHC_VERSION/bin/haddock" >> $GITHUB_ENV
84-
echo "CABAL=/opt/cabal/3.2/bin/cabal -vnormal+nowrap" >> $GITHUB_ENV
86+
echo "HCPKG=$HCDIR/bin/$HCNAME-pkg" >> $GITHUB_ENV
87+
echo "HADDOCK=$HCDIR/bin/haddock" >> $GITHUB_ENV
88+
echo "CABAL=/opt/cabal/3.4/bin/cabal -vnormal+nowrap" >> $GITHUB_ENV
8589
HCNUMVER=$(${HC} --numeric-version|perl -ne '/^(\d+)\.(\d+)\.(\d+)(\.(\d+))?$/; print(10000 * $1 + 100 * $2 + ($3 == 0 ? $5 != 1 : $3))')
8690
echo "HCNUMVER=$HCNUMVER" >> $GITHUB_ENV
8791
echo "ARG_TESTS=--enable-tests" >> $GITHUB_ENV
8892
echo "ARG_BENCH=--enable-benchmarks" >> $GITHUB_ENV
89-
echo "ARG_COMPILER=--ghc --with-compiler=/opt/ghc/$GHC_VERSION/bin/ghc" >> $GITHUB_ENV
93+
echo "HEADHACKAGE=false" >> $GITHUB_ENV
94+
echo "ARG_COMPILER=--$HCNAME --with-compiler=$HC" >> $GITHUB_ENV
9095
echo "GHCJSARITH=0" >> $GITHUB_ENV
9196
env:
92-
GHC_VERSION: ${{ matrix.ghc }}
97+
CC: ${{ matrix.compiler }}
9398
- name: env
9499
run: |
95100
env
@@ -134,10 +139,14 @@ jobs:
134139
uses: actions/checkout@v2
135140
with:
136141
path: source
142+
- name: initial cabal.project for sdist
143+
run: |
144+
touch cabal.project
145+
echo "packages: $GITHUB_WORKSPACE/source/." >> cabal.project
146+
cat cabal.project
137147
- name: sdist
138148
run: |
139149
mkdir -p sdist
140-
cd source || false
141150
$CABAL sdist all --output-dir $GITHUB_WORKSPACE/sdist
142151
- name: unpack
143152
run: |
@@ -164,9 +173,9 @@ jobs:
164173
- name: cache
165174
uses: actions/cache@v2
166175
with:
167-
key: ${{ runner.os }}-${{ matrix.ghc }}-${{ github.sha }}
176+
key: ${{ runner.os }}-${{ matrix.compiler }}-${{ github.sha }}
168177
path: ~/.cabal/store
169-
restore-keys: ${{ runner.os }}-${{ matrix.ghc }}-
178+
restore-keys: ${{ runner.os }}-${{ matrix.compiler }}-
170179
- name: install dependencies
171180
run: |
172181
$CABAL v2-build $ARG_COMPILER --disable-tests --disable-benchmarks --dependencies-only -j2 all

CONTRIBUTING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ Patches welcome!
44
- If it's really **only bounds**, please simply open an issue (so you'll have a URL to refer to). I have a semi-automated process to make revisions, pull requests only disturb it.
55
- If patch includes **source code change** (i.e. I'll need to make a release), and it's a patch to support **newer base/GHC version**:
66
- Amend `tested-with` to include that GHC
7-
- Regenerate `.travis.yml` with `haskell-ci regenerate` (get the latest from [GitHub haskell-ci/haskell-ci](https://github.com/haskell-ci/haskell-ci))
7+
- Regenerate `.github/workflows/haskell-ci.yml` with `haskell-ci regenerate` (get the latest from [GitHub haskell-ci/haskell-ci](https://github.com/haskell-ci/haskell-ci))
88

99
- Don't edit `CHANGELOG.md`, rather include a copyable entry in your pull request description. I often process pull requests in bulk, and everyone editing the `CHANGELOG.md` causes unnecessary conflicts.
1010
- For the same reason, do not edit `version` or `x-revision`

0 commit comments

Comments
 (0)