jaredly / jaredly/reason-language-server
vim-lsp support (formatting not working)
- Dominant language
- OCaml
- Stars
- 649
- Forks
- 85
- PR merge metrics
- No merged PRs in 30d
Description
Hi everyone, this is great - I've been trying to get this working with https://github.com/prabirshrestha/vim-lsp but have trouble running the formatting command:
```
"https://github.com/jaredly/reason-language-server/releases/latest/download/bin.exe
if executable('reason-language-server')
au User lsp_setup call lsp#register_server({
\ 'name': 'reason-language-server',
\ 'cmd': {server_info->[&shell, &shellcmdflag, 'reason-language-server --stdio']},
\ 'root_uri':{server_info->lsp#utils#path_to_uri(lsp#utils#find_nearest_parent_file_directory(lsp#utils#get_buffer_path(), 'bsconfig.json'))},
\ 'whitelist': ['reason'],
\ })
endif
```
This seems to work for [ocaml](https://github.com/prabirshrestha/vim-lsp/wiki/Servers-OCaml---Reason):
```
if executable('ocaml-language-server')
au User lsp_setup call lsp#register_server({
\ 'name': 'ocaml-language-server',
\ 'cmd': {server_info->[&shell, &shellcmdflag, 'ocaml-language-server --stdio']},
\ 'whitelist': ['reason', 'ocaml'],
\ })
endif
```
Thanks!
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with the vim-lsp configuration in the issue, especially the reason-language-server --stdio command and the formatting command that fails. Compare it with the working ocaml-language-server configuration and investigate how reason-language-server handles formatting. Done means formatting works through vim-lsp for Reason files.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- ocaml, vim
- Domain
- developer-experience, tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100