Skip to content

Commit

Permalink
feat: add support for dcm lsp
Browse files Browse the repository at this point in the history
  • Loading branch information
RobertBrunhage committed Jan 12, 2024
1 parent f5dab13 commit 5ab0eb2
Show file tree
Hide file tree
Showing 3 changed files with 79 additions and 0 deletions.
30 changes: 30 additions & 0 deletions doc/server_configurations.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ autogenerated from the Lua files. You can view this file in Nvim by running
- [dafny](#dafny)
- [dagger](#dagger)
- [dartls](#dartls)
- [dcmls](#dcmls)
- [denols](#denols)
- [dhall_lsp_server](#dhall_lsp_server)
- [diagnosticls](#diagnosticls)
Expand Down Expand Up @@ -2417,6 +2418,35 @@ require'lspconfig'.dartls.setup{}
```


## dcmls

https://dcm.dev/

Language server for dart.



**Snippet to enable the language server:**
```lua
require'lspconfig'.dcmls.setup{}
```


**Default values:**
- `cmd` :
```lua
{ "dcm", "start-server" }
```
- `filetypes` :
```lua
{ "dart" }
```
- `root_dir` :
```lua
root_pattern("pubspec.yaml")
```


## denols

https://github.com/denoland/deno
Expand Down
30 changes: 30 additions & 0 deletions doc/server_configurations.txt
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ autogenerated from the Lua files. You can view this file in Nvim by running
- [dafny](#dafny)
- [dagger](#dagger)
- [dartls](#dartls)
- [dcmls](#dcmls)
- [denols](#denols)
- [dhall_lsp_server](#dhall_lsp_server)
- [diagnosticls](#diagnosticls)
Expand Down Expand Up @@ -2417,6 +2418,35 @@ require'lspconfig'.dartls.setup{}
```


## dcmls

https://dcm.dev/

Language server for dart.



**Snippet to enable the language server:**
```lua
require'lspconfig'.dcmls.setup{}
```


**Default values:**
- `cmd` :
```lua
{ "dcm", "start-server" }
```
- `filetypes` :
```lua
{ "dart" }
```
- `root_dir` :
```lua
root_pattern("pubspec.yaml")
```


## denols

https://github.com/denoland/deno
Expand Down
19 changes: 19 additions & 0 deletions lua/lspconfig/server_configurations/dcmls.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
local util = require 'lspconfig.util'

return {
default_config = {
cmd = { 'dcm', 'start-server' },
filetypes = { 'dart' },
root_dir = util.root_pattern 'pubspec.yaml',
},
docs = {
description = [[
https://dcm.dev/
Language server for dart.
]],
default_config = {
root_dir = [[root_pattern("pubspec.yaml")]],
},
},
}

0 comments on commit 5ab0eb2

Please sign in to comment.