From bf5f8fd3828698b28f5c307af6cc21ffe9fffb5b Mon Sep 17 00:00:00 2001 From: Oleg Grenrus Date: Sat, 6 Mar 2021 23:34:15 +0200 Subject: [PATCH] Allow base-4.15 --- .github/workflows/haskell-ci.yml | 47 +++++++++++++++++++++++--------- cabal.project | 4 +++ github.cabal | 9 +++--- samples/github-samples.cabal | 5 ++-- 4 files changed, 46 insertions(+), 19 deletions(-) diff --git a/.github/workflows/haskell-ci.yml b/.github/workflows/haskell-ci.yml index 2dd020d0..637021b1 100644 --- a/.github/workflows/haskell-ci.yml +++ b/.github/workflows/haskell-ci.yml @@ -8,9 +8,9 @@ # # For more information, see https://github.com/haskell-CI/haskell-ci # -# version: 0.11.20201213 +# version: 0.11.20210222 # -# REGENDATA ("0.11.20201213",["--config=cabal.haskell-ci","github","cabal.project"]) +# REGENDATA ("0.11.20210222",["--config=cabal.haskell-ci","github","cabal.project"]) # name: Haskell-CI on: @@ -22,21 +22,32 @@ on: - master jobs: linux: - name: Haskell-CI Linux + name: Haskell-CI - Linux - GHC ${{ matrix.ghc }} runs-on: ubuntu-18.04 container: image: buildpack-deps:bionic + continue-on-error: ${{ matrix.allow-failure }} strategy: matrix: include: - - ghc: 8.10.1 - - ghc: 8.8.3 + - ghc: 9.0.1 + allow-failure: false + - ghc: 8.10.4 + allow-failure: false + - ghc: 8.8.4 + allow-failure: false - ghc: 8.6.5 + allow-failure: false - ghc: 8.4.4 + allow-failure: false - ghc: 8.2.2 + allow-failure: false - ghc: 8.0.2 + allow-failure: false - ghc: 7.10.3 + allow-failure: false - ghc: 7.8.4 + allow-failure: false fail-fast: false steps: - name: apt @@ -45,7 +56,7 @@ jobs: apt-get install -y --no-install-recommends gnupg ca-certificates dirmngr curl git software-properties-common apt-add-repository -y 'ppa:hvr/ghc' apt-get update - apt-get install -y ghc-$GHC_VERSION cabal-install-3.2 + apt-get install -y ghc-$GHC_VERSION cabal-install-3.4 env: GHC_VERSION: ${{ matrix.ghc }} - name: Set PATH and environment variables @@ -58,12 +69,13 @@ jobs: echo "HC=$HC" >> $GITHUB_ENV echo "HCPKG=/opt/ghc/$GHC_VERSION/bin/ghc-pkg" >> $GITHUB_ENV echo "HADDOCK=/opt/ghc/$GHC_VERSION/bin/haddock" >> $GITHUB_ENV - echo "CABAL=/opt/cabal/3.2/bin/cabal -vnormal+nowrap" >> $GITHUB_ENV + echo "CABAL=/opt/cabal/3.4/bin/cabal -vnormal+nowrap" >> $GITHUB_ENV HCNUMVER=$(${HC} --numeric-version|perl -ne '/^(\d+)\.(\d+)\.(\d+)(\.(\d+))?$/; print(10000 * $1 + 100 * $2 + ($3 == 0 ? $5 != 1 : $3))') echo "HCNUMVER=$HCNUMVER" >> $GITHUB_ENV echo "ARG_TESTS=--enable-tests" >> $GITHUB_ENV echo "ARG_BENCH=--enable-benchmarks" >> $GITHUB_ENV - echo "ARG_COMPILER=--ghc --with-compiler=/opt/ghc/$GHC_VERSION/bin/ghc" >> $GITHUB_ENV + echo "HEADHACKAGE=false" >> $GITHUB_ENV + echo "ARG_COMPILER=--ghc --with-compiler=$HC" >> $GITHUB_ENV echo "GHCJSARITH=0" >> $GITHUB_ENV env: GHC_VERSION: ${{ matrix.ghc }} @@ -75,7 +87,7 @@ jobs: mkdir -p $CABAL_DIR cat >> $CABAL_CONFIG < $HOME/.cabal/bin/cabal-plan rm -f cabal-plan.xz chmod a+x $HOME/.cabal/bin/cabal-plan + cabal-plan --version - name: checkout uses: actions/checkout@v2 with: path: source + - name: initial cabal.project for sdist + run: | + touch cabal.project + echo "packages: $GITHUB_WORKSPACE/source/." >> cabal.project + echo "packages: $GITHUB_WORKSPACE/source/samples" >> cabal.project + cat cabal.project - name: sdist run: | mkdir -p sdist - cd source || false $CABAL sdist all --output-dir $GITHUB_WORKSPACE/sdist - name: unpack run: | @@ -138,6 +156,9 @@ jobs: constraints: semigroups ^>=0.19 constraints: github +openssl constraints: github-samples +openssl + allow-newer: deepseq-generics-0.2.0.0:base + allow-newer: deepseq-generics-0.2.0.0:ghc-prim + allow-newer: cryptohash-sha1-0.11.100.1:base optimization: False EOF $HCPKG list --simple-output --names-only | perl -ne 'for (split /\s+/) { print "constraints: $_ installed\n" unless /^(github|github-samples)$/; }' >> cabal.project.local @@ -155,14 +176,14 @@ jobs: restore-keys: ${{ runner.os }}-${{ matrix.ghc }}- - name: install dependencies run: | - $CABAL v2-build $ARG_COMPILER --disable-tests --disable-benchmarks --dependencies-only all - $CABAL v2-build $ARG_COMPILER $ARG_TESTS $ARG_BENCH --dependencies-only all + $CABAL v2-build $ARG_COMPILER --disable-tests --disable-benchmarks --dependencies-only -j2 all + $CABAL v2-build $ARG_COMPILER $ARG_TESTS $ARG_BENCH --dependencies-only -j2 all - name: build w/o tests run: | $CABAL v2-build $ARG_COMPILER --disable-tests --disable-benchmarks all - name: build run: | - $CABAL v2-build $ARG_COMPILER $ARG_TESTS $ARG_BENCH all + $CABAL v2-build $ARG_COMPILER $ARG_TESTS $ARG_BENCH all --write-ghc-environment-files=always - name: tests run: | $CABAL v2-test $ARG_COMPILER $ARG_TESTS $ARG_BENCH all --test-show-details=direct diff --git a/cabal.project b/cabal.project index 555119f5..5e40418a 100644 --- a/cabal.project +++ b/cabal.project @@ -9,3 +9,7 @@ constraints: semigroups ^>=0.19 constraints: github +openssl constraints: github-samples +openssl + +allow-newer: deepseq-generics-0.2.0.0:base +allow-newer: deepseq-generics-0.2.0.0:ghc-prim +allow-newer: cryptohash-sha1-0.11.100.1:base diff --git a/github.cabal b/github.cabal index 1b4f2e40..348a9345 100644 --- a/github.cabal +++ b/github.cabal @@ -27,7 +27,7 @@ maintainer: Oleg Grenrus homepage: https://github.com/phadej/github build-type: Simple copyright: - Copyright 2012-2013 Mike Burns, Copyright 2013-2015 John Wiegley, Copyright 2016-2019 Oleg Grenrus + Copyright 2012-2013 Mike Burns, Copyright 2013-2015 John Wiegley, Copyright 2016-2021 Oleg Grenrus tested-with: GHC ==7.8.4 @@ -36,8 +36,9 @@ tested-with: || ==8.2.2 || ==8.4.4 || ==8.6.5 - || ==8.8.3 - || ==8.10.1 + || ==8.8.4 + || ==8.10.4 + || ==9.0.1 extra-source-files: README.md @@ -164,7 +165,7 @@ library -- Packages bundles with GHC, mtl and text are also here build-depends: - base >=4.7 && <4.15 + base >=4.7 && <4.16 , binary >=0.7.1.0 && <0.11 , bytestring >=0.10.4.0 && <0.11 , containers >=0.5.5.1 && <0.7 diff --git a/samples/github-samples.cabal b/samples/github-samples.cabal index 41d6dccf..270609d7 100644 --- a/samples/github-samples.cabal +++ b/samples/github-samples.cabal @@ -15,8 +15,9 @@ tested-with: || ==8.2.2 || ==8.4.4 || ==8.6.5 - || ==8.8.3 - || ==8.10.1 + || ==8.8.4 + || ==8.10.4 + || ==9.0.1 library hs-source-dirs: src