diff --git a/docs/install.md b/docs/install.md index ba9d199..6a3dff8 100644 --- a/docs/install.md +++ b/docs/install.md @@ -209,6 +209,16 @@ The developers of the Haskell Language Server offer an [extension](https://githu 3. Make sure your project uses the GHC version installed from GHCup (otherwise HLS is likely to fail on launch): - instructions for [stack](https://docs.haskellstack.org/en/stable/yaml_configuration/#system-ghc) +On Linux, some users have reported an issue when VSCode is not launched from a terminal ("cannot find ghc version"). A [solution](https://github.com/haskell/vscode-haskell#stackcabalghc-can-not-be-found) is to let HLS know about your GHCup on $PATH. To do this: + +1. In VSCode type `Ctrl + ,`, then`_haskell server`, then under _Haskell: Server Environment_, click the `Edit in settings.json` link and then insert the following: +``` + "haskell.serverEnvironment": { + "PATH": "${HOME}/.ghcup/bin:$PATH" + } +``` +2. Restart your workspace for the change to apply. + ## Get help * [Libera IRC chat on #haskell-ghcup or #haskell](https://kiwiirc.com/nextclient/irc.libera.chat/?nick=Guest%7C?#haskell,#haskell-ghcup)