Skip to content

Commit

Permalink
Add Lite-XL Editor Guide (#337)
Browse files Browse the repository at this point in the history
  • Loading branch information
colinkiama authored Aug 20, 2023
1 parent a5929bb commit b55b145
Show file tree
Hide file tree
Showing 2 changed files with 40 additions and 0 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ _add LSP configurations using serve-d for other editors and PR them here!_
* [emacs](editor-emacs.md)
* [Helix](editor-helix.md)
* [Nova](editor-nova.md)
* [Lite-XL](editor.lite-xl.md)

### Project Layout

Expand Down
39 changes: 39 additions & 0 deletions editor-lite-xl.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# Using serve-d with Lite-XL
---

Requirments:
- lite-xl-lsp Plugin: https://github.com/lite-xl/lite-xl-lsp

Add the following to your user `init.lua` file (Access it quickly with `Core: Open User Module` command):

```lua
local lsp = require "plugins.lsp"

lsp.add_server {
name = "serve-d",
language = "d",
file_patterns = { "%.d$" },
command = { "serve-d" },
incremental_changes = true,
}
```

To add settings, include a table of settings to pass to the LSP:

```lua
local lsp = require "plugins.lsp"

lsp.add_server {
name = "serve-d",
language = "d",
file_patterns = { "%.d$" },
command = { "serve-d" },
incremental_changes = true,
settings = {
d = {
enableAutoComplete = false,
}
}
}
```

0 comments on commit b55b145

Please sign in to comment.