From 6085ee38bf9cc27bf0b7cac9354431291a8823ac Mon Sep 17 00:00:00 2001 From: Andreas Abel Date: Fri, 8 Dec 2023 12:31:17 +0100 Subject: [PATCH] v0.8.3.0-r1: allow text-2.1, tasty-1.5, and containers-0.7 (#65) --- .github/workflows/haskell-ci.yml | 72 ++++++++++++++++++++------------ blaze-markup.cabal | 21 +++++----- cabal.haskell-ci | 16 ++++--- 3 files changed, 66 insertions(+), 43 deletions(-) diff --git a/.github/workflows/haskell-ci.yml b/.github/workflows/haskell-ci.yml index bf67364..d87f6d7 100644 --- a/.github/workflows/haskell-ci.yml +++ b/.github/workflows/haskell-ci.yml @@ -6,22 +6,20 @@ # # haskell-ci regenerate # -# For more information, see https://github.com/haskell-CI/haskell-ci +# For more information, see https://github.com/andreasabel/haskell-ci # -# version: 0.16.4 +# version: 0.17.20230928 # -# REGENDATA ("0.16.4",["github","blaze-markup.cabal"]) +# REGENDATA ("0.17.20230928",["github","blaze-markup.cabal"]) # name: Haskell-CI on: push: branches: - master - - ci* pull_request: branches: - master - - ci* jobs: linux: name: Haskell-CI - Linux - ${{ matrix.compiler }} @@ -29,19 +27,24 @@ jobs: timeout-minutes: 60 container: - image: buildpack-deps:bionic + image: buildpack-deps:focal continue-on-error: ${{ matrix.allow-failure }} strategy: matrix: include: - - compiler: ghc-9.6.2 + - compiler: ghc-9.8.0.20230919 compilerKind: ghc - compilerVersion: 9.6.2 + compilerVersion: 9.8.0.20230919 + setup-method: ghcup + allow-failure: true + - compiler: ghc-9.6.3 + compilerKind: ghc + compilerVersion: 9.6.3 setup-method: ghcup allow-failure: false - - compiler: ghc-9.4.5 + - compiler: ghc-9.4.7 compilerKind: ghc - compilerVersion: 9.4.5 + compilerVersion: 9.4.7 setup-method: ghcup allow-failure: false - compiler: ghc-9.2.8 @@ -89,11 +92,6 @@ jobs: compilerVersion: 7.10.3 setup-method: hvr-ppa allow-failure: false - - compiler: ghc-7.8.4 - compilerKind: ghc - compilerVersion: 7.8.4 - setup-method: hvr-ppa - allow-failure: false fail-fast: false steps: - name: apt @@ -102,8 +100,9 @@ jobs: apt-get install -y --no-install-recommends gnupg ca-certificates dirmngr curl git software-properties-common libtinfo5 if [ "${{ matrix.setup-method }}" = ghcup ]; then mkdir -p "$HOME/.ghcup/bin" - curl -sL https://downloads.haskell.org/ghcup/0.1.19.2/x86_64-linux-ghcup-0.1.19.2 > "$HOME/.ghcup/bin/ghcup" + curl -sL https://downloads.haskell.org/ghcup/0.1.19.5/x86_64-linux-ghcup-0.1.19.5 > "$HOME/.ghcup/bin/ghcup" chmod a+x "$HOME/.ghcup/bin/ghcup" + "$HOME/.ghcup/bin/ghcup" config add-release-channel https://raw.githubusercontent.com/haskell/ghcup-metadata/master/ghcup-prereleases-0.0.7.yaml; "$HOME/.ghcup/bin/ghcup" install ghc "$HCVER" || (cat "$HOME"/.ghcup/logs/*.* && false) "$HOME/.ghcup/bin/ghcup" install cabal 3.10.1.0 || (cat "$HOME"/.ghcup/logs/*.* && false) else @@ -111,8 +110,9 @@ jobs: apt-get update apt-get install -y "$HCNAME" mkdir -p "$HOME/.ghcup/bin" - curl -sL https://downloads.haskell.org/ghcup/0.1.19.2/x86_64-linux-ghcup-0.1.19.2 > "$HOME/.ghcup/bin/ghcup" + curl -sL https://downloads.haskell.org/ghcup/0.1.19.5/x86_64-linux-ghcup-0.1.19.5 > "$HOME/.ghcup/bin/ghcup" chmod a+x "$HOME/.ghcup/bin/ghcup" + "$HOME/.ghcup/bin/ghcup" config add-release-channel https://raw.githubusercontent.com/haskell/ghcup-metadata/master/ghcup-prereleases-0.0.7.yaml; "$HOME/.ghcup/bin/ghcup" install cabal 3.10.1.0 || (cat "$HOME"/.ghcup/logs/*.* && false) fi env: @@ -127,10 +127,12 @@ jobs: echo "CABAL_CONFIG=$HOME/.cabal/config" >> "$GITHUB_ENV" HCDIR=/opt/$HCKIND/$HCVER if [ "${{ matrix.setup-method }}" = ghcup ]; then - HC=$HOME/.ghcup/bin/$HCKIND-$HCVER + HC=$("$HOME/.ghcup/bin/ghcup" whereis ghc "$HCVER") + HCPKG=$(echo "$HC" | sed 's#ghc$#ghc-pkg#') + HADDOCK=$(echo "$HC" | sed 's#ghc$#haddock#') echo "HC=$HC" >> "$GITHUB_ENV" - echo "HCPKG=$HOME/.ghcup/bin/$HCKIND-pkg-$HCVER" >> "$GITHUB_ENV" - echo "HADDOCK=$HOME/.ghcup/bin/haddock-$HCVER" >> "$GITHUB_ENV" + echo "HCPKG=$HCPKG" >> "$GITHUB_ENV" + echo "HADDOCK=$HADDOCK" >> "$GITHUB_ENV" echo "CABAL=$HOME/.ghcup/bin/cabal-3.10.1.0 -vnormal+nowrap" >> "$GITHUB_ENV" else HC=$HCDIR/bin/$HCKIND @@ -144,7 +146,7 @@ jobs: echo "HCNUMVER=$HCNUMVER" >> "$GITHUB_ENV" echo "ARG_TESTS=--enable-tests" >> "$GITHUB_ENV" echo "ARG_BENCH=--enable-benchmarks" >> "$GITHUB_ENV" - echo "HEADHACKAGE=false" >> "$GITHUB_ENV" + if [ $((HCNUMVER >= 90800)) -ne 0 ] ; then echo "HEADHACKAGE=true" >> "$GITHUB_ENV" ; else echo "HEADHACKAGE=false" >> "$GITHUB_ENV" ; fi echo "ARG_COMPILER=--$HCKIND --with-compiler=$HC" >> "$GITHUB_ENV" echo "GHCJSARITH=0" >> "$GITHUB_ENV" env: @@ -173,6 +175,18 @@ jobs: repository hackage.haskell.org url: http://hackage.haskell.org/ EOF + if $HEADHACKAGE; then + cat >> $CABAL_CONFIG <> $CABAL_CONFIG <= 80200)) -ne 0 ] ; then echo "package blaze-markup" >> cabal.project ; fi if [ $((HCNUMVER >= 80200)) -ne 0 ] ; then echo " ghc-options: -Werror=missing-methods" >> cabal.project ; fi cat >> cabal.project <> cabal.project + fi $HCPKG list --simple-output --names-only | perl -ne 'for (split /\s+/) { print "constraints: $_ installed\n" unless /^(blaze-markup)$/; }' >> cabal.project.local cat cabal.project cat cabal.project.local @@ -265,11 +281,13 @@ jobs: - name: prepare for constraint sets run: | rm -f cabal.project.local - - name: constraint set bytestring-0.12 + - name: constraint set latest-core-libs-Sep-2023 run: | - if [ $((HCNUMVER >= 80200)) -ne 0 ] ; then $CABAL v2-build $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='bytestring ^>=0.12.0.0' --dependencies-only -j2 all ; fi - if [ $((HCNUMVER >= 80200)) -ne 0 ] ; then $CABAL v2-build $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='bytestring ^>=0.12.0.0' all ; fi - if [ $((HCNUMVER >= 80200)) -ne 0 ] ; then $CABAL v2-test $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='bytestring ^>=0.12.0.0' all ; fi + if [ $((HCNUMVER >= 80200 && HCNUMVER < 90800)) -ne 0 ] ; then $CABAL v2-build $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='bytestring >= 0.12' --constraint='text >= 2.1' --constraint='containers >= 0.7' all --dry-run ; fi + if [ $((HCNUMVER >= 80200 && HCNUMVER < 90800)) -ne 0 ] ; then cabal-plan topo | sort ; fi + if [ $((HCNUMVER >= 80200 && HCNUMVER < 90800)) -ne 0 ] ; then $CABAL v2-build $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='bytestring >= 0.12' --constraint='text >= 2.1' --constraint='containers >= 0.7' --dependencies-only -j2 all ; fi + if [ $((HCNUMVER >= 80200 && HCNUMVER < 90800)) -ne 0 ] ; then $CABAL v2-build $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='bytestring >= 0.12' --constraint='text >= 2.1' --constraint='containers >= 0.7' all ; fi + if [ $((HCNUMVER >= 80200 && HCNUMVER < 90800)) -ne 0 ] ; then $CABAL v2-test $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='bytestring >= 0.12' --constraint='text >= 2.1' --constraint='containers >= 0.7' all ; fi - name: save cache uses: actions/cache/save@v3 if: always() diff --git a/blaze-markup.cabal b/blaze-markup.cabal index db59302..89282cb 100644 --- a/blaze-markup.cabal +++ b/blaze-markup.cabal @@ -1,5 +1,7 @@ +Cabal-version: >= 1.10 Name: blaze-markup Version: 0.8.3.0 +x-revision: 1 Homepage: http://jaspervdj.be/blaze Bug-Reports: http://github.com/jaspervdj/blaze-markup/issues License: BSD3 @@ -16,11 +18,11 @@ Description: . Build-type: Simple -Cabal-version: >= 1.10 Tested-with: - GHC == 9.6.2 - GHC == 9.4.5 + GHC == 9.8.0 + GHC == 9.6.3 + GHC == 9.4.7 GHC == 9.2.8 GHC == 9.0.2 GHC == 8.10.7 @@ -30,7 +32,6 @@ Tested-with: GHC == 8.2.2 GHC == 8.0.2 GHC == 7.10.3 - GHC == 7.8.4 Extra-source-files: CHANGELOG @@ -49,10 +50,10 @@ Library Text.Blaze.Renderer.Utf8 Build-depends: - base >= 4 && < 5, - blaze-builder >= 0.3 && < 0.5, - text >= 0.10 && < 2.1, - bytestring >= 0.9 && < 0.13 + base >= 4 && < 5 + , blaze-builder >= 0.3 && < 0.5 + , text >= 0.10 && < 2.2 + , bytestring >= 0.9 && < 0.13 Test-suite blaze-markup-tests Type: exitcode-stdio-1.0 @@ -80,8 +81,8 @@ Test-suite blaze-markup-tests -- Extra dependencies , HUnit >= 1.2 && < 1.7 , QuickCheck >= 2.7 && < 2.15 - , containers >= 0.3 && < 0.7 - , tasty >= 1.0 && < 1.5 + , containers >= 0.3 && < 0.8 + , tasty >= 1.0 && < 1.6 , tasty-hunit >= 0.10 && < 0.11 , tasty-quickcheck >= 0.10 && < 0.11 diff --git a/cabal.haskell-ci b/cabal.haskell-ci index 829a63c..29fe9e2 100644 --- a/cabal.haskell-ci +++ b/cabal.haskell-ci @@ -1,9 +1,13 @@ -branches: master ci* +branches: master -constraint-set bytestring-0.12 - ghc: >=8.2 - constraints: bytestring ^>=0.12.0.0 +-- Test core libraries in versions newer than shipped with GHC +constraint-set latest-core-libs-Sep-2023 + constraints: bytestring >= 0.12 + constraints: text >= 2.1 + constraints: containers >= 0.7 + ghc: >=8.2 && < 9.7 tests: True run-tests: True -raw-project - allow-newer: bytestring + +-- raw-project +-- allow-newer: bytestring