Improve warnAboutHlsCompatibility
This commit is contained in:
parent
c163278c64
commit
ae2031174e
12
lib/GHCup.hs
12
lib/GHCup.hs
@ -1031,11 +1031,13 @@ warnAboutHlsCompatibility = do
|
|||||||
|
|
||||||
case (currentGHC, currentHLS) of
|
case (currentGHC, currentHLS) of
|
||||||
(Just gv, Just hv) | gv `notElem` supportedGHC -> do
|
(Just gv, Just hv) | gv `notElem` supportedGHC -> do
|
||||||
logWarn $ "GHC " <> T.pack (prettyShow gv) <> " is not compatible with "
|
logWarn $
|
||||||
<> "Haskell Language Server " <> T.pack (prettyShow hv) <> "."
|
"GHC " <> T.pack (prettyShow gv) <> " is not compatible with " <>
|
||||||
logWarn "Haskell IDE support may not work until this is fixed."
|
"Haskell Language Server " <> T.pack (prettyShow hv) <> "." <> "\n" <>
|
||||||
logWarn $ "Install a different HLS version, or run `ghcup list` to see "
|
"Haskell IDE support may not work until this is fixed." <> "\n" <>
|
||||||
<> "supported GHC versions."
|
"Install a different HLS version, or install and set one of the following GHCs:" <> "\n" <>
|
||||||
|
T.pack (prettyShow supportedGHC)
|
||||||
|
|
||||||
_ -> return ()
|
_ -> return ()
|
||||||
|
|
||||||
------------------
|
------------------
|
||||||
|
@ -475,7 +475,7 @@ hlsGHCVersions = do
|
|||||||
. splitOn "~"
|
. splitOn "~"
|
||||||
)
|
)
|
||||||
bins
|
bins
|
||||||
pure . rights . concat . maybeToList $ vers
|
pure . sortBy (flip compare) . rights . concat . maybeToList $ vers
|
||||||
|
|
||||||
|
|
||||||
-- | Get all server binaries for an hls version, if any.
|
-- | Get all server binaries for an hls version, if any.
|
||||||
|
Loading…
Reference in New Issue
Block a user