From 3292a2b28e06f354a1108684bcba47fb10482a9d Mon Sep 17 00:00:00 2001 From: Veronika Romashkina Date: Sun, 20 Oct 2024 15:12:01 +0100 Subject: [PATCH] Upgrade to newer GHCs (#32) * Upgrade to newer GHCs * Trigger CI * Upgrade Cabal on CI * Upgrade actions versions * Remove support of GHC 8.2 * Change the version of he package --- .github/workflows/ci.yml | 39 +++++++++++++++++++++++---------------- CHANGELOG.md | 6 ++++++ shellmet.cabal | 22 ++++++++++++++++------ src/Shellmet.hs | 4 ++++ 4 files changed, 49 insertions(+), 22 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 35c1de9..b60ff04 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -5,9 +5,6 @@ on: types: [synchronize, opened, reopened] push: branches: [main] - schedule: - # additionally run once per week (At 00:00 on Sunday) to maintain cache - - cron: "0 0 * * 0" jobs: cabal: @@ -16,16 +13,27 @@ jobs: strategy: matrix: os: [ubuntu-latest, macOS-latest] - cabal: ["3.6.2.0"] + cabal: ["3.12"] ghc: - - 8.2.2 - 8.4.4 - 8.6.5 - 8.8.4 - 8.10.7 - 9.0.2 - - 9.2.3 + - 9.2.8 + - 9.4.7 + - 9.6.6 + - 9.8.2 + - 9.10.1 exclude: + - os: macOS-latest + ghc: 9.8.2 + - os: macOS-latest + ghc: 9.6.6 + - os: macOS-latest + ghc: 9.4.7 + - os: macOS-latest + ghc: 9.2.8 - os: macOS-latest ghc: 9.0.2 - os: macOS-latest @@ -36,13 +44,12 @@ jobs: ghc: 8.6.5 - os: macOS-latest ghc: 8.4.4 - - os: macOS-latest - ghc: 8.2.2 + steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - - uses: haskell/actions/setup@v1 + - uses: haskell/actions/setup@v2.3 id: setup-haskell-cabal name: Setup Haskell with: @@ -57,7 +64,7 @@ jobs: run: | cabal freeze - - uses: actions/cache@v2.1.3 + - uses: actions/cache@v4 name: Cache ~/.cabal/store with: path: ${{ steps.setup-haskell-cabal.outputs.cabal-store }} @@ -84,19 +91,19 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - stack: ["2.7.5"] - ghc: ["9.2.3"] + stack: ["2.9"] + ghc: ["9.4.7"] steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - - uses: haskell/actions/setup@v1 + - uses: haskell/actions/setup@v2.3 name: Setup Haskell Stack with: ghc-version: ${{ matrix.ghc }} stack-version: ${{ matrix.stack }} - - uses: actions/cache@v3 + - uses: actions/cache@v4 name: Cache ~/.stack with: path: ~/.stack diff --git a/CHANGELOG.md b/CHANGELOG.md index de6b578..5fd2333 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,12 @@ `shellmet` uses [PVP Versioning][1]. The changelog is available [on GitHub][2]. +## 0.0.5.0 — Oct 20, 2024 + +* Support GHC 9.2.8. 9.4.7, 9.6.6, 9.8.2, 9.10.1. +* Upgrade `text` from `1.2.3` to `2.0.0`. +* Remove support of GHC 8.2.2. + ## 0.0.4.1 — Jun 13, 2022 * [#28](https://github.com/kowainik/shellmet/issues/28): diff --git a/shellmet.cabal b/shellmet.cabal index 169d477..9c79281 100644 --- a/shellmet.cabal +++ b/shellmet.cabal @@ -1,6 +1,6 @@ cabal-version: 2.4 name: shellmet -version: 0.0.4.1 +version: 0.0.5.0 synopsis: Out of the shell solution for scripting in Haskell description: Shellmet provides easy and convenient way to call shell commands from Haskell programs homepage: https://github.com/kowainik/shellmet @@ -14,20 +14,23 @@ category: Shell, Command Line build-type: Simple extra-doc-files: README.md CHANGELOG.md -tested-with: GHC == 8.2.2 - GHC == 8.4.4 +tested-with: GHC == 8.4.4 GHC == 8.6.5 GHC == 8.8.4 GHC == 8.10.7 GHC == 9.0.2 - GHC == 9.2.3 + GHC == 9.2.8 + GHC == 9.4.7 + GHC == 9.6.6 + GHC == 9.8.2 + GHC == 9.10.1 source-repository head type: git location: https://github.com/kowainik/shellmet.git common common-options - build-depends: base >= 4.10.1.0 && < 4.17 + build-depends: base >= 4.11.1.0 && < 4.21 ghc-options: -Wall -Wcompat @@ -49,6 +52,13 @@ common common-options if impl(ghc >= 9.2) ghc-options: -Wredundant-bang-patterns -Woperator-whitespace + if impl(ghc >= 9.4 && < 9.10) + ghc-options: -Wforall-identifier + if impl(ghc >= 9.4) + ghc-options: -Wredundant-strictness-flags + if impl(ghc >= 9.8) + ghc-options: -Wterm-variable-capture + -Winconsistent-flags default-language: Haskell2010 default-extensions: ConstraintKinds @@ -71,7 +81,7 @@ library exposed-modules: Shellmet build-depends: process ^>= 1.6.1 - , text >= 1.2.3 && < 2.1 + , text >= 1.2.3 && < 2.2 executable readme import: common-options diff --git a/src/Shellmet.hs b/src/Shellmet.hs index 703ff66..b95a1c7 100644 --- a/src/Shellmet.hs +++ b/src/Shellmet.hs @@ -1,7 +1,11 @@ {-# OPTIONS_GHC -fno-warn-orphans #-} +{-# LANGUAGE CPP #-} {-# LANGUAGE FlexibleInstances #-} {-# LANGUAGE TypeFamilies #-} +#if __GLASGOW_HASKELL__ >= 904 +{-# LANGUAGE TypeOperators #-} +#endif {- | Module : Shellmet