From 5c7c28060c65435ef87f0bf1ce5c689f548ee41d Mon Sep 17 00:00:00 2001 From: Tony Zorman Date: Fri, 18 Nov 2022 19:17:04 +0100 Subject: [PATCH] ci: Drop support for GHC 8.4 Debian stable is not on 8.6, which was always our guide as to which GHC versions we want to support. In particular, this lets us get rid of all the quickcheck-classes special treatment. Related: https://github.com/xmonad/xmonad/commit/400730fe3b8aab8e7f9403215c88b37e44fe7a66 --- .github/workflows/haskell-ci.yml | 5 ----- .github/workflows/stack.yml | 1 - CHANGES.md | 2 ++ stack.yaml | 7 ------- tests/Properties/Stack.hs | 10 ---------- xmonad.cabal | 14 ++++---------- 6 files changed, 6 insertions(+), 33 deletions(-) diff --git a/.github/workflows/haskell-ci.yml b/.github/workflows/haskell-ci.yml index 2715295..1b54726 100644 --- a/.github/workflows/haskell-ci.yml +++ b/.github/workflows/haskell-ci.yml @@ -66,11 +66,6 @@ jobs: compilerVersion: 8.6.5 setup-method: hvr-ppa allow-failure: false - - compiler: ghc-8.4.4 - compilerKind: ghc - compilerVersion: 8.4.4 - setup-method: hvr-ppa - allow-failure: false fail-fast: false steps: - name: apt diff --git a/.github/workflows/stack.yml b/.github/workflows/stack.yml index e169cd4..36bdcd1 100644 --- a/.github/workflows/stack.yml +++ b/.github/workflows/stack.yml @@ -12,7 +12,6 @@ jobs: fail-fast: false matrix: include: - - resolver: lts-12 # GHC 8.4 - resolver: lts-14 # GHC 8.6 - resolver: lts-16 # GHC 8.8 - resolver: lts-18 # GHC 8.10 diff --git a/CHANGES.md b/CHANGES.md index 5da39ae..f26f2a6 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -4,6 +4,8 @@ ### Breaking Changes +* Dropped support for GHC 8.4. + ### Enhancements * Exported `sendRestart` and `sendReplace` from `XMonad.Operations`. diff --git a/stack.yaml b/stack.yaml index 2ec4a08..99ffada 100644 --- a/stack.yaml +++ b/stack.yaml @@ -6,13 +6,6 @@ packages: extra-deps: - X11-1.10 -flags: - xmonad: - # stack doesn't support automatic flags - # https://cabal.readthedocs.io/en/latest/cabal-package.html#resolution-of-conditions-and-flags - # https://github.com/commercialhaskell/stack/issues/1313#issuecomment-157259270 - quickcheck-classes: false - nix: packages: - zlib diff --git a/tests/Properties/Stack.hs b/tests/Properties/Stack.hs index f85ca3e..a833ce1 100644 --- a/tests/Properties/Stack.hs +++ b/tests/Properties/Stack.hs @@ -1,9 +1,5 @@ -{-# LANGUAGE CPP #-} {-# LANGUAGE ScopedTypeVariables #-} - -#ifdef VERSION_quickcheck_classes {-# LANGUAGE GeneralizedNewtypeDeriving #-} -#endif module Properties.Stack where @@ -15,13 +11,11 @@ import qualified XMonad.StackSet as S (filter) import Data.Maybe -#ifdef VERSION_quickcheck_classes import Data.Proxy import Test.QuickCheck.Classes ( Laws (lawsTypeclass, lawsProperties), Proxy1 (Proxy1), foldableLaws, traversableLaws, ) -#endif -- The list returned by index should be the same length as the actual @@ -65,7 +59,6 @@ prop_differentiate xs = where _ = xs :: [Int] -#ifdef VERSION_quickcheck_classes -- Check type class laws of 'Data.Foldable.Foldable' and 'Data.Traversable.Traversable'. newtype TestStack a = TestStack (Stack a) deriving (Eq, Read, Show, Foldable, Functor) @@ -82,6 +75,3 @@ prop_laws_Stack = format (foldableLaws p) <> format (traversableLaws p) p = Proxy :: Proxy TestStack format laws = [ ("Stack: " <> lawsTypeclass laws <> ": " <> name, prop) | (name, prop) <- lawsProperties laws ] -#else -prop_laws_Stack = [] -#endif diff --git a/xmonad.cabal b/xmonad.cabal index da24c52..a26797b 100644 --- a/xmonad.cabal +++ b/xmonad.cabal @@ -27,7 +27,7 @@ author: Spencer Janssen, Don Stewart, Adam Vogt, David Roundy, Jason Ondřej Súkup, Paul Hebble, Shachaf Ben-Kiki, Siim Põder, Tim McIver, Trevor Elliott, Wouter Swierstra, Conrad Irwin, Tim Thelion, Tony Zorman maintainer: xmonad@haskell.org -tested-with: GHC == 8.4.4 || == 8.6.5 || == 8.8.4 || == 8.10.7 || == 9.0.2 || == 9.2.5 || == 9.4.2 +tested-with: GHC == 8.6.5 || == 8.8.4 || == 8.10.7 || == 9.0.2 || == 9.2.5 || == 9.4.2 category: System homepage: http://xmonad.org bug-reports: https://github.com/xmonad/xmonad/issues @@ -54,8 +54,6 @@ flag pedantic default: False manual: True -flag quickcheck-classes - library exposed-modules: XMonad XMonad.Config @@ -83,7 +81,7 @@ library default-language: Haskell2010 -- Keep this in sync with the oldest version in 'tested-with' - if impl(ghc > 8.4.4) + if impl(ghc > 8.6.5) ghc-options: -Wno-unused-imports if flag(pedantic) @@ -96,7 +94,7 @@ executable xmonad default-language: Haskell2010 -- Keep this in sync with the oldest version in 'tested-with' - if impl(ghc > 8.4.4) + if impl(ghc > 8.6.5) ghc-options: -Wno-unused-imports if flag(pedantic) @@ -125,15 +123,11 @@ test-suite properties hs-source-dirs: tests build-depends: base , QuickCheck >= 2 + , quickcheck-classes >= 0.4.3 , X11 , containers , xmonad default-language: Haskell2010 - if flag(quickcheck-classes) && impl(ghc > 8.5) - -- no quickcheck-classes in LTS-12 - -- GHC 8.4 and lower needs too much boilerplate (Eq1, Show1, …) - build-depends: quickcheck-classes >= 0.4.3 - if flag(pedantic) ghc-options: -Werror