From 7a2570019a8b014b7b84dbaa172629d85ce75ce1 Mon Sep 17 00:00:00 2001 From: Julian Ospald Date: Tue, 20 Jul 2021 11:42:36 +0200 Subject: [PATCH] Return the version during 'ghcup compile ghc -g ' Fixes #181 --- app/ghcup/Main.hs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/app/ghcup/Main.hs b/app/ghcup/Main.hs index 3c37ec1..30459f1 100644 --- a/app/ghcup/Main.hs +++ b/app/ghcup/Main.hs @@ -1930,14 +1930,15 @@ Report bugs at |] let vi = getVersionInfo (_tvVersion targetVer) GHC dls when setCompile $ void $ liftE $ setGHC targetVer SetGHCOnly - pure vi + pure (vi, targetVer) ) >>= \case - VRight vi -> do + VRight (vi, tv) -> do runLogger $ $(logInfo) "GHC successfully compiled and installed" forM_ (_viPostInstall =<< vi) $ \msg -> runLogger $ $(logInfo) msg + putStr (T.unpack $ tVerToText tv) pure ExitSuccess VLeft (V (AlreadyInstalled _ v)) -> do runLogger $ $(logWarn)