File tree 1 file changed +5
-3
lines changed
1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -9,7 +9,6 @@ module Main where
9
9
10
10
import Control.Monad.Extra
11
11
import Data.Default
12
- import Data.Either.Extra (eitherToMaybe )
13
12
import Data.Foldable
14
13
import Data.List
15
14
import Data.List.Extra (trimEnd )
@@ -76,8 +75,11 @@ main = do
76
75
putStrLn $ showProgramVersionOfInterest programsOfInterest
77
76
putStrLn " Tool versions in your project"
78
77
cradle <- findProjectCradle' recorder False
79
- ghcVersion <- runExceptT $ getRuntimeGhcVersion' cradle
80
- putStrLn $ showProgramVersion " ghc" $ mkVersion =<< eitherToMaybe ghcVersion
78
+ runExceptT (getRuntimeGhcVersion' cradle) >>= \ case
79
+ Left err ->
80
+ T. hPutStrLn stderr (prettyError err NoShorten )
81
+ Right ghcVersion ->
82
+ putStrLn $ showProgramVersion " ghc" $ mkVersion ghcVersion
81
83
82
84
VersionMode PrintVersion ->
83
85
putStrLn hlsVer
You can’t perform that action at this time.
0 commit comments