8000 Add support for summoning GHC 9.2.8, 9.4.8, and 9.6.6 by noughtmare · Pull Request #570 · kowainik/summoner · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Add support for summoning GHC 9.2.8, 9.4.8, and 9.6.6 #570

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Sep 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -96,28 +96,28 @@ jobs:
run: |
cabal test all

- if: matrix.ghc == '9.0.2'
- if: matrix.ghc == '9.6.6'
name: Build 'cabal-minimal'
run: |
cd "summoner-cli/examples/cabal-minimal/"
echo "packages: ." > cabal.project
cabal build all

- if: matrix.ghc == '9.0.2'
- if: matrix.ghc == '9.6.6'
name: Build 'cabal-full'
run: |
cd "summoner-cli/examples/cabal-full/"
echo "packages: ." > cabal.project
cabal build all

- if: matrix.ghc == '9.0.2'
- if: matrix.ghc == '9.6.6'
name: Build 'stack-full'
run: |
cd "summoner-cli/examples/stack-full/"
echo "packages: ." > cabal.project
cabal build all

- if: matrix.ghc == '9.0.2'
- if: matrix.ghc == '9.6.6'
name: Build 'full-batteries'
run: |
cd "summoner-cli/examples/full-batteries/"
Expand Down
15 changes: 15 additions & 0 deletions summoner-cli/examples/cabal-full/.github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,16 @@ jobs:
- "8.8.4"
- "8.10.7"
- "9.0.2"
- "9.2.8"
- "9.4.8"
- "9.6.6"
exclude:
- os: macOS-latest
ghc: 9.4.8
- os: macOS-latest
ghc: 9.2.8
- os: macOS-latest
ghc: 9.0.2
- os: macOS-latest
ghc: 8.10.7
- os: macOS-latest
Expand All @@ -32,6 +41,12 @@ jobs:
ghc: 8.6.5
- os: macOS-latest
ghc: 8.4.4
- os: windows-latest
ghc: 9.4.8
- os: windows-latest
ghc: 9.2.8
- os: windows-latest
ghc: 9.0.2
- os: windows-latest
ghc: 8.10.7
- os: windows-latest
Expand Down
3 changes: 3 additions & 0 deletions summoner-cli/examples/cabal-full/.travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ jobs:
- ghc: 8.8.4
- ghc: 8.10.7
- ghc: 9.0.2
- ghc: 9.2.8
- ghc: 9.4.8
- ghc: 9.6.6

install:
# HLint check
Expand Down
4 changes: 2 additions & 2 deletions summoner-cli/examples/cabal-full/appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,12 @@ environment:
CABOPTS: --store-dir=C:\\SR

matrix:
- GHCVER: 9.0.2
- GHCVER: 9.6.6

install:
- choco source add -n mistuke -s https://www.myget.org/F/mistuke/api/v2
- choco install -y cabal --version 3.6.2.0
- choco install -y ghc --version 9.0.2
- choco install -y ghc --version 9.6.6
- refreshenv

before_build:
Expand Down
5 changes: 4 additions & 1 deletion summoner-cli/examples/cabal-full/cabal-full.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,16 @@ tested-with: GHC == 8.4.4
GHC == 8.8.4
GHC == 8.10.7
GHC == 9.0.2
GHC == 9.2.8
GHC == 9.4.8
GHC == 9.6.6

source-repository head
type: git
location: https://github.com/kowainik/cabal-full.git

common common-options
build-depends: base >= 4.11.1.0 && < 4.16
build-depends: base >= 4.11.1.0 && < 4.19
, relude

mixins: base hiding (Prelude)
Expand Down
4 changes: 2 additions & 2 deletions summoner-cli/examples/cabal-minimal/cabal-minimal.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@ copyright: 2022 Kowainik
build-type: Simple
extra-doc-files: README.md
CHANGELOG.md
tested-with: GHC == 9.0.2
tested-with: GHC == 9.6.6

common common-options
build-depends: base ^>= 4.15.1.0
build-depends: base ^>= 4.18.2.1

ghc-options: -Wall
-Wcompat
Expand Down
2 changes: 1 addition & 1 deletion summoner-cli/examples/cabalScript.hs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/usr/bin/env cabal
{- cabal:
build-depends:
, base ^>= 4.15.1.0
, base ^>= 4.18.2.1
-}

main :: IO ()
Expand Down
18 changes: 18 additions & 0 deletions summoner-cli/examples/full-batteries/.github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,16 @@ jobs:
- "8.8.4"
- "8.10.7"
- "9.0.2"
- "9.2.8"
- "9.4.8"
- "9.6.6"
exclude:
- os: macOS-latest
ghc: 9.4.8
- os: macOS-latest
ghc: 9.2.8
- os: macOS-latest
ghc: 9.0.2
- os: macOS-latest
ghc: 8.10.7
- os: macOS-latest
Expand All @@ -38,6 +47,12 @@ jobs:
ghc: 8.2.2
- os: macOS-latest
ghc: 8.0.2
- os: windows-latest
ghc: 9.4.8
- os: windows-latest
ghc: 9.2.8
- os: windows-latest
ghc: 9.0.2
- os: windows-latest
ghc: 8.10.7
- os: windows-latest
Expand Down Expand Up @@ -106,6 +121,9 @@ jobs:
- "8.8.4"
- "8.10.7"
- "9.0.2"
- "9.2.8"
- "9.4.8"
- "9.6.6"

steps:
- uses: actions/checkout@v2
Expand Down
12 changes: 12 additions & 0 deletions summoner-cli/examples/full-batteries/.travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@ jobs:
- ghc: 8.8.4
- ghc: 8.10.7
- ghc: 9.0.2
- ghc: 9.2.8
- ghc: 9.4.8
- ghc: 9.6.6

- ghc: 8.0.2
env: STACK_YAML="$TRAVIS_BUILD_DIR/stack-8.0.2.yaml"
Expand All @@ -40,6 +43,15 @@ jobs:
env: STACK_YAML="$TRAVIS_BUILD_DIR/stack-8.10.7.yaml"

- ghc: 9.0.2
env: STACK_YAML="$TRAVIS_BUILD_DIR/stack-9.0.2.yaml"

- ghc: 9.2.8
env: STACK_YAML="$TRAVIS_BUILD_DIR/stack-9.2.8.yaml"

- ghc: 9.4.8
env: STACK_YAML="$TRAVIS_BUILD_DIR/stack-9.4.8.yaml"

- ghc: 9.6.6
env: STACK_YAML="$TRAVIS_BUILD_DIR/stack.yaml"

allow_failures:
Expand Down
4 changes: 2 additions & 2 deletions summoner-cli/examples/full-batteries/appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,12 @@ environment:
CABOPTS: --store-dir=C:\\SR

matrix:
- GHCVER: 9.0.2
- GHCVER: 9.6.6

install:
- choco source add -n mistuke -s https://www.myget.org/F/mistuke/api/v2
- choco install -y cabal --version 3.6.2.0
- choco install -y ghc --version 9.0.2
- choco install -y ghc --version 9.6.6
- refreshenv

before_build:
Expand Down
5 changes: 4 additions & 1 deletion summoner-cli/examples/full-batteries/full-batteries.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,16 @@ tested-with: GHC == 8.0.2
GHC == 8.8.4
GHC == 8.10.7
GHC == 9.0.2
GHC == 9.2.8
GHC == 9.4.8
GHC == 9.6.6

source-repository head
type: git
location: https://github.com/kowainik/full-batteries.git

common common-options
build-depends: base >= 4.9.1.0 && < 4.16
build-depends: base >= 4.9.1.0 && < 4.19
, relude

mixins: base hiding (Prelude)
Expand Down
2 changes: 1 addition & 1 deletion summoner-cli/examples/full-batteries/stack-8.10.7.yaml
Original file line number Diff line number Diff line change
@@ -1 +1 @@
resolver: lts-18.21
resolver: lts-18.28
1 change: 1 addition & 0 deletions summoner-cli/examples/full-batteries/stack-9.0.2.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
resolver: lts-19.33
1 change: 1 addition & 0 deletions summoner-cli/examples/full-batteries/stack-9.2.8.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
resolver: lts-20.26
1 change: 1 addition & 0 deletions summoner-cli/examples/full-batteries/stack-9.4.8.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
resolver: lts-21.25
2 changes: 1 addition & 1 deletion summoner-cli/examples/full-batteries/stack.yaml
Original file line number Diff line number Diff line change
@@ -1 +1 @@
resolver: nightly-2022-01-10
resolver: lts-22.34
3 changes: 3 additions & 0 deletions summoner-cli/examples/stack-full/.github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@ jobs:
- "8.8.4"
- "8.10.7"
- "9.0.2"
- "9.2.8"
- "9.4.8"
- "9.6.6"

steps:
- uses: actions/checkout@v2
Expand Down
9 changes: 9 additions & 0 deletions summoner-cli/examples/stack-full/.travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,15 @@ jobs:
env: STACK_YAML="$TRAVIS_BUILD_DIR/stack-8.10.7.yaml"

- ghc: 9.0.2
env: STACK_YAML="$TRAVIS_BUILD_DIR/stack-9.0.2.yaml"

- ghc: 9.2.8
env: STACK_YAML="$TRAVIS_BUILD_DIR/stack-9.2.8.yaml"

- ghc: 9.4.8
env: STACK_YAML="$TRAVIS_BUILD_DIR/stack-9.4.8.yaml"

- ghc: 9.6.6
env: STACK_YAML="$TRAVIS_BUILD_DIR/stack.yaml"

allow_failures:
Expand Down
2 changes: 1 addition & 1 deletion summoner-cli/examples/stack-full/stack-8.10.7.yaml
Original file line number Diff line number Diff line change
@@ -1 +1 @@
resolver: lts-18.21
resolver: lts-18.28
1 change: 1 addition & 0 deletions summoner-cli/examples/stack-full/stack-9.0.2.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
resolver: lts-19.33
1 change: 1 addition & 0 deletions summoner-cli/examples/stack-full/stack-9.2.8.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
resolver: lts-20.26
1 change: 1 addition & 0 deletions summoner-cli/examples/stack-full/stack-9.4.8.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
resolver: lts-21.25
5 changes: 4 additions & 1 deletion summoner-cli/examples/stack-full/stack-full.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,16 @@ tested-with: GHC == 8.4.4
GHC == 8.8.4
GHC == 8.10.7
GHC == 9.0.2
GHC == 9.2.8
GHC == 9.4.8
GHC == 9.6.6

source-repository head
type: git
location: https://github.com/kowainik/stack-full.git

common common-options
build-depends: base >= 4.11.1.0 && < 4.16
build-depends: base >= 4.11.1.0 && < 4.19
, relude

mixins: base hiding (Prelude)
Expand Down
2 changes: 1 addition & 1 deletion summoner-cli/examples/stack-full/stack.yaml
Original file line number Diff line number Diff line change
@@ -1 +1 @@
resolver: nightly-2022-01-10
resolver: lts-22.34
2 changes: 1 addition & 1 deletion summoner-cli/examples/stackScript.hs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/usr/bin/env stack
{- stack
--resolver nightly-2022-01-10
--resolver lts-22.34
script
--package base
-}
Expand Down
4 changes: 2 additions & 2 deletions summoner-cli/examples/summoner-default.toml
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,9 @@ license = "MIT"
# travis = true # Travis CI
# appveyor = true # AppVeyor CI

# List of additional GHC versions to support besides 9.0.2.
# List of additional GHC versions to support besides 9.6.6.
# Run the 'summon show ghc' command to see the list of all supported GHC versions.
# ghcVersions = ["8.8.4", "8.10.7"]
# ghcVersions = ["9.2.8", "9.4.8"]

# List of default-extensions in the .cabal file
# extensions = [ "ConstraintKinds"
Expand Down
16 changes: 14 additions & 2 deletions summoner-cli/src/Summoner/GhcVer.hs
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,9 @@ data GhcVer
| Ghc884
| Ghc8107
| Ghc902
| Ghc928
| Ghc945
| Ghc966
deriving stock (Eq, Ord, Show, Enum, Bounded)

-- | Converts 'GhcVer' into dot-separated string.
Expand All @@ -49,6 +52,9 @@ showGhcVer = \case
Ghc884 -> "8.8.4"
Ghc8107 -> "8.10.7"
Ghc902 -> "9.0.2"
Ghc928 -> "9.2.8"
Ghc945 -> "9.4.8"
Ghc966 -> "9.6.6"

{- | These are old GHC versions that are not working with default GHC versions
when using Stack.
Expand All @@ -67,8 +73,11 @@ latestLts = \case
Ghc844 -> "lts-12.26"
Ghc865 -> "lts-14.27"
Ghc884 -> "lts-16.31"
Ghc8107 -> "lts-18.21"
Ghc902 -> "nightly-2022-01-10"
Ghc8107 -> "lts-18.28"
Ghc902 -> "lts-19.33"
Ghc928 -> "lts-20.26"
Ghc945 -> "lts-21.25"
Ghc966 -> "lts-22.34"

-- | Represents PVP versioning (4 numbers).
data Pvp = Pvp
Expand All @@ -92,6 +101,9 @@ baseVerPvp = \case
Ghc884 -> Pvp 4 13 0 0
Ghc8107 -> Pvp 4 14 3 0
Ghc902 -> Pvp 4 15 1 0
Ghc928 -> Pvp 4 16 4 0
Ghc945 -> Pvp 4 17 0 0
Ghc966 -> Pvp 4 18 2 1

-- | Returns corresponding @base@ version of the given GHC version.
baseVer :: GhcVer -> Text
Expand Down
7 changes: 5 additions & 2 deletions summoner-cli/test/Test/Show.hs
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@ goldenGhcTable =
, "GHC-8.4.4 base-4.11.1.0 lts-12.26"
, "GHC-8.6.5 base-4.12.0.0 lts-14.27"
, "GHC-8.8.4 base-4.13.0.0 lts-16.31"
, "GHC-8.10.7 base-4.14.3.0 lts-18.21"
, "GHC-9.0.2 base-4.15.1.0 nightly-2022-01-10"
, "GHC-8.10.7 base-4.14.3.0 lts-18.28"
, "GHC-9.0.2 base-4.15.1.0 lts-19.33"
, "GHC-9.2.8 base-4.16.4.0 lts-20.26"
, "GHC-9.4.8 base-4.17.0.0 lts-21.25"
, "GHC-9.6.6 base-4.18.2.1 lts-22.34"
]
Loading
0