Skip to content

Commit

Permalink
Update CI, don't drop servant-0.19
Browse files Browse the repository at this point in the history
  • Loading branch information
jhrcek committed Dec 7, 2023
1 parent 7f0f48f commit 978d7ac
Show file tree
Hide file tree
Showing 8 changed files with 25 additions and 29 deletions.
17 changes: 9 additions & 8 deletions .github/workflows/haskell-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,13 @@ jobs:
matrix:
os:
- ubuntu-latest
cabal: [3.8]
cabal:
- '3.10.2.0'
ghc:
- 8.10.7
- 9.0.2
- 9.2.5
- 9.4.4
- 9.2.8
- 9.4.8
- 9.6.3
steps:
- uses: actions/checkout@v3
if: github.event.action == 'opened' || github.event.action == 'synchronize' || github.event.ref == 'refs/heads/master'
Expand Down Expand Up @@ -49,12 +50,12 @@ jobs:
strategy:
matrix:
stack:
- 2.9.3
- 2.13.1
stack-yaml:
- stack-8.10.7.yaml
- stack-9.0.2.yaml
- stack-9.2.5.yaml

- stack-9.2.8.yaml
- stack-9.4.8.yaml
- stack-9.6.3.yaml
steps:
- uses: actions/checkout@v3
if: github.event.action == 'opened' || github.event.action == 'synchronize' || github.event.ref == 'refs/heads/master'
Expand Down
12 changes: 6 additions & 6 deletions servant-hmac-auth.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@ category: Web, Cryptography
build-type: Simple
extra-source-files: README.md
, CHANGELOG.md
tested-with: GHC == 8.10.7
GHC == 9.0.2
GHC == 9.2.5
GHC == 9.4.4
tested-with: GHC == 9.0.2
GHC == 9.2.8
GHC == 9.4.8
GHC == 9.6.3

source-repository head
type: git
Expand Down Expand Up @@ -76,7 +76,7 @@ library
, memory >= 0.15 && < 0.19
, mtl ^>= 2.2.2 || ^>= 2.3
, servant ^>= 0.18 || ^>= 0.19 || ^>= 0.20
, servant-client ^>= 0.20
, servant-client ^>= 0.19 || ^>= 0.20
, servant-client-core ^>= 0.18 || ^>= 0.19 || ^>= 0.20
, servant-server ^>= 0.18 || ^>= 0.19 || ^>= 0.20
, transformers ^>= 0.5 || ^>= 0.6
Expand All @@ -95,7 +95,7 @@ test-suite servant-hmac-auth-test
, hspec-golden ^>= 0.2
, http-client >= 0.6.4 && < 0.8
, http-types ^>= 0.12
, servant-client ^>= 0.20
, servant-client ^>= 0.19 || ^>= 0.20
, servant-server ^>= 0.18 || ^>= 0.19 || ^>= 0.20
, text
, warp ^>= 3.3
Expand Down
11 changes: 7 additions & 4 deletions src/Servant/Auth/Hmac/Client.hs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
{-# LANGUAGE AllowAmbiguousTypes #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE InstanceSigs #-}
{-# LANGUAGE CPP #-}

-- | Servant client authentication.
module Servant.Auth.Hmac.Client (
Expand Down Expand Up @@ -120,10 +121,12 @@ hmacClient = Proxy @api `clientIn` Proxy @HmacClientM

servantRequestToPayload :: BaseUrl -> Servant.Request -> IO RequestPayload
servantRequestToPayload url sreq = do
req <-
defaultMakeClientRequest
url
sreq
#if MIN_VERSION_servant_client(0,20,0)
req <- -- servant-client 0.20: defaultMakeClientRequest :: BaseUrl -> Request -> IO Request
#else
let req = -- servant-client 0.12: defaultMakeClientRequest :: BaseUrl -> Request -> Request
#endif
defaultMakeClientRequest url sreq
{ Servant.requestQueryString =
fromList $ sort $ toList $ Servant.requestQueryString sreq
}
Expand Down
10 changes: 0 additions & 10 deletions stack-8.10.7.yaml

This file was deleted.

1 change: 0 additions & 1 deletion stack-9.2.5.yaml

This file was deleted.

1 change: 1 addition & 0 deletions 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 stack-9.4.8.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
resolver: lts-21.23
1 change: 1 addition & 0 deletions stack-9.6.3.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
resolver: nightly-2023-12-07

0 comments on commit 978d7ac

Please sign in to comment.