Skip to content

Commit

Permalink
Run hover extensions without shell
Browse files Browse the repository at this point in the history
  • Loading branch information
fwcd committed Dec 4, 2024
1 parent 0445022 commit e3a8738
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Curry/LanguageServer/Handlers/TextDocument/Hover.hs
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ import qualified Language.LSP.Protocol.Lens as J
import qualified Language.LSP.Protocol.Message as J
import Language.LSP.Server (MonadLsp)
import System.Exit (ExitCode (..))
import System.Process (readCreateProcessWithExitCode, shell, CreateProcess (..))
import System.Process (readCreateProcessWithExitCode, proc)
import System.Timeout (timeout)

hoverHandler :: S.Handlers LSM
Expand Down Expand Up @@ -83,7 +83,7 @@ extensionHover ast pos e = case e.extensionPoint of
timeoutMicros = timeoutSecs * 1_000_000
-- TODO: Template parameters
-- TODO: cwd
procOpts = shell (unwords (T.unpack <$> (e.executable : e.args)))
procOpts = proc (T.unpack e.executable) (T.unpack <$> e.args)

(exitCode, out, err) <- MaybeT $ liftIO $ timeout timeoutMicros $ readCreateProcessWithExitCode procOpts ""

Expand Down

0 comments on commit e3a8738

Please sign in to comment.