[Test] Stack: use ghc-* resolver based on ghc version
This commit is contained in:
parent
dd45f6e31d
commit
05d87f4175
@ -56,7 +56,13 @@ main = do
|
||||
|
||||
let stackDir = "test/data/stack-project"
|
||||
void $ withDirectory_ stackDir $ do
|
||||
-- void $ system "stack init --force"
|
||||
let ghcver = let gvn = show (__GLASGOW_HASKELL__ :: Int)
|
||||
(major, minor') = splitAt (length gvn - 2) gvn
|
||||
minor = case dropWhile (=='0') minor' of
|
||||
"" -> "0"
|
||||
x -> x
|
||||
in major ++ "." ++ minor
|
||||
void $ system $ "stack init --force --resolver=ghc-" ++ ghcver
|
||||
void $ system "stack setup"
|
||||
void $ system "stack build"
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user