From f5b685a162a89b1d6fe1e9eba8b67554c6de3f4e Mon Sep 17 00:00:00 2001 From: jneira Date: Sat, 6 Mar 2021 22:55:33 +0100 Subject: [PATCH] Demote implicit cradle warn to logging --- ghcide/session-loader/Development/IDE/Session.hs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ghcide/session-loader/Development/IDE/Session.hs b/ghcide/session-loader/Development/IDE/Session.hs index e725c6acc4..1461a70b17 100644 --- a/ghcide/session-loader/Development/IDE/Session.hs +++ b/ghcide/session-loader/Development/IDE/Session.hs @@ -395,8 +395,8 @@ loadSessionWithOptions SessionLoadingOptions{..} dir = do lfp <- flip makeRelative cfp <$> getCurrentDirectory logInfo logger $ T.pack ("Consulting the cradle for " <> show lfp) - when (isNothing hieYaml) $ mRunLspT lspEnv $ - sendNotification SWindowShowMessage $ notifyUserImplicitCradle lfp + when (isNothing hieYaml) $ + logWarning logger $ implicitCradleWarning lfp cradle <- maybe (loadImplicitHieCradle $ addTrailingPathSeparator dir) loadCradle hieYaml @@ -820,8 +820,8 @@ getCacheDirsDefault prefix opts = do cacheDir :: String cacheDir = "ghcide" -notifyUserImplicitCradle:: FilePath -> ShowMessageParams -notifyUserImplicitCradle fp =ShowMessageParams MtWarning $ +implicitCradleWarning :: FilePath -> T.Text +implicitCradleWarning fp = "No [cradle](https://github.com/mpickering/hie-bios#hie-bios) found for " <> T.pack fp <> ".\n Proceeding with [implicit cradle](https://hackage.haskell.org/package/implicit-hie).\n"<>