Skip to content

Commit 329bbd2

Browse files
committed
Retain the --lsp option, to not break existing clients
PR haskell#1489 removed the --lsp option, resulting in a hard failure if a client uses it to start up the server. Parse it, but ignore it, as an interim measure.
1 parent 23892ca commit 329bbd2

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/Haskell/Ide/Engine/Options.hs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import Options.Applicative.Simple
66
data GlobalOpts = GlobalOpts
77
{ optDebugOn :: Bool
88
, optLogFile :: Maybe String
9+
, _optLsp :: Bool -- Kept for a while, to not break legacy clients
910
, projectRoot :: Maybe String
1011
, optBiosVerbose :: Bool
1112
, optCaptureFile :: Maybe FilePath
@@ -25,6 +26,9 @@ globalOptsParser = GlobalOpts
2526
<> metavar "LOGFILE"
2627
<> help "File to log to, defaults to stdout"
2728
))
29+
<*> flag True True
30+
( long "lsp"
31+
<> help "Legacy flag, no longer used, to enable LSP mode. Not required.")
2832
<*> optional (strOption
2933
( long "project-root"
3034
<> short 'r'

0 commit comments

Comments
 (0)