Improve documentation on Language Server installation (#2037)

This commit is contained in:
Michael Davis 2022-04-09 01:47:32 -05:00 committed by GitHub
parent 0b410b0a16
commit 78b1600943
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 11 additions and 1 deletions

View File

@ -55,6 +55,10 @@ # Installation
> NOTE: running via cargo also doesn't require setting explicit `HELIX_RUNTIME` path, it will automatically
> detect the `runtime` directory in the project root.
In order to use LSP features like auto-complete, you will need to
[install the appropriate Language Server](https://github.com/helix-editor/helix/wiki/How-to-install-the-default-language-servers)
for a language.
[![Packaging status](https://repology.org/badge/vertical-allrepos/helix.svg)](https://repology.org/project/helix/versions)
## MacOS

View File

@ -16,6 +16,7 @@ ## Language configuration
file-types = ["mylang", "myl"]
comment-token = "#"
indent = { tab-width = 2, unit = " " }
language-server = { command = "mylang-lsp", args = ["--stdio"] }
```
These are the available keys and descriptions for the file.
@ -32,9 +33,14 @@ ## Language configuration
| `diagnostic-severity` | Minimal severity of diagnostic for it to be displayed. (Allowed values: `Error`, `Warning`, `Info`, `Hint`) |
| `comment-token` | The token to use as a comment-token |
| `indent` | The indent to use. Has sub keys `tab-width` and `unit` |
| `config` | Language server configuration |
| `language-server` | The Language Server to run. Has sub keys `command` and `args` |
| `config` | Language Server configuration |
| `grammar` | The tree-sitter grammar to use (defaults to the value of `name`) |
When adding a Language Server configuration, be sure to update the
[Language Server Wiki](https://github.com/helix-editor/helix/wiki/How-to-install-the-default-language-servers)
with installation notes.
## Grammar configuration
If a tree-sitter grammar is available for the language, add a new `grammar`