You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
-[It's time to join the project!](#its-time-to-join-the-project)
34
43
@@ -276,9 +285,149 @@ dependencies:
276
285
277
286
## Editor Integration
278
287
279
-
Note to editor integrators: there is now a haskell-language-server-wrapper executable, which is installed alongside the haskell-language-server executable. When this is invoked in the project root directory, it attempts to work out the GHC version used in the project, and then launch the matching haskell-language-server executable.
288
+
Note to editor integrators: there is a `haskell-language-server-wrapper` executable, which is installed alongside the `haskell-language-server` executable. When this is invoked in the project root directory, it attempts to work out the GHC version used in the project, and then launch the matching `haskell-language-server` executable.
280
289
281
-
All of the editor integrations assume that you have already installed haskell-language-server (see above) and that the installation script put the haskell-language-server binary in your path (usually `~/.local/bin` or `~/.cabal/bin` on linux and macOS).
290
+
All of the editor integrations assume that you have already installed `haskell-language-server` (see above) and that the installation script put the `haskell-language-server` and `haskell-language-server-wrapper` binaries in your `PATH` (usually `~/.local/bin` or `~/.cabal/bin` on Linux and macOS, `%APPDATA%\local\bin` or `%APPDATA%\cabal\bin` on Windows).
291
+
292
+
### Using Haskell Language Server with VS Code
293
+
294
+
Install from
295
+
[the VSCode marketplace](https://marketplace.visualstudio.com/items?itemName=alanz.vscode-hie-server), or manually from the repository [vscode-hie-server](https://github.com/alanz/vscode-hie-server).
296
+
297
+
Choose `haskell-language-server` in the extension setting `languageServerHaskell.hieVariant`.
298
+
299
+
### Using Haskell Language Server with Sublime Text
300
+
301
+
- Install [LSP](https://packagecontrol.io/packages/LSP) using [Package Control](https://packagecontrol.io/)
302
+
- From Sublime Text, go to Preferences and search for LSP Settings
303
+
- Paste in these settings. Make sure to change the command path to your `haskell-language-server-wrapper`
Then issue `:CocConfig` and add the following to your Coc config file.
335
+
336
+
```json
337
+
"languageserver": {
338
+
"haskell": {
339
+
"command": "haskell-language-server-wrapper",
340
+
"args": ["--lsp"],
341
+
"rootPatterns": [
342
+
"*.cabal",
343
+
"stack.yaml",
344
+
"cabal.project",
345
+
"package.yaml"
346
+
],
347
+
"filetypes": [
348
+
"hs",
349
+
"lhs",
350
+
"haskell"
351
+
],
352
+
"initializationOptions": {
353
+
"languageServerHaskell": {
354
+
}
355
+
}
356
+
}
357
+
}
358
+
```
359
+
360
+
#### LanguageClient-neovim
361
+
362
+
##### vim-plug
363
+
364
+
If you use [vim-plug](https://github.com/junegunn/vim-plug), then you can do this by e.g.,
365
+
including the following line in the Plug section of your `init.vim` or `~/.vimrc`:
366
+
367
+
```text
368
+
Plug 'autozimu/LanguageClient-neovim', {
369
+
\ 'branch': 'next',
370
+
\ 'do': 'bash install.sh'
371
+
\ }
372
+
```
373
+
374
+
and issuing a `:PlugInstall` command within Neovim or Vim.
375
+
376
+
##### Clone the LanguageClient-neovim repo
377
+
378
+
As an alternative to using [vim-plug](https://github.com/junegunn/vim-plug) shown above, clone [LanguageClient-neovim](https://github.com/autozimu/LanguageClient-neovim)
379
+
into `~/.vim/pack/XXX/start/`, where `XXX` is just a name for your "plugin suite".
380
+
381
+
##### Sample `~/.vimrc`
382
+
383
+
```vim
384
+
set rtp+=~/.vim/pack/XXX/start/LanguageClient-neovim
385
+
let g:LanguageClient_serverCommands = { 'haskell': ['haskell-language-server-wrapper', '--lsp'] }
386
+
```
387
+
388
+
You'll probably want to add some mappings for common commands:
The plugin ide-haskell-hie is designed to work with haskell-ide-engine by default, so you will have to put the path to haskell-language-server-wrapper in the configuration option `Absolute path to hie executable`.
282
431
283
432
### Using haskell-language-server with Emacs
284
433
@@ -300,11 +449,10 @@ Make sure to follow the instructions in the README of each of these packages.
300
449
)
301
450
```
302
451
303
-
304
-
305
452
### Using haskell-language-server with [doom-emacs](https://github.com/hlissner/doom-emacs/tree/develop/modules/lang/haskell#module-flags)
306
453
307
454
Install haskell-language-server, and then enable haskell lang module with lsp flag in `.doom.d/init.el`
455
+
308
456
``` emacs-lisp
309
457
:lang
310
458
(haskell +lsp)
@@ -324,7 +472,6 @@ in your `.doom.d/config.el` file
324
472
325
473
then do `$HOME/.emacs.d/bin/doom refresh`
326
474
327
-
328
475
### Using haskell-language-server with [Kakoune](https://github.com/mawww/kakoune)
329
476
330
477
1. Grab a copy of [kak-lsp](https://github.com/ul/kak-lsp), and follow the setup instructions.
@@ -340,7 +487,7 @@ args = ["--lsp"]
340
487
341
488
## Contributing
342
489
343
-
### It's time to join the project!
490
+
### It's time to join the project
344
491
345
492
:heart: Haskell tooling dream is near, we need your help! :heart:
0 commit comments