Skip to content

Commit

Permalink
feat(buf): new lsp for protobuf (#3414)
Browse files Browse the repository at this point in the history
new server bufls for protobuf filetype
  • Loading branch information
gogamid authored Nov 6, 2024
1 parent dff0299 commit 2e92288
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lua/lspconfig.lua
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,10 @@ local aliases = {
to = 'ts_ls',
version = '0.2.1',
},
bufls = {
to = 'bufls',
version = '0.2.1',
},
}

---@return Alias
Expand Down
16 changes: 16 additions & 0 deletions lua/lspconfig/configs/buf_ls.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
return {
default_config = {
cmd = { 'buf', 'beta', 'lsp', '--timeout=0', '--log-format=text' },
filetypes = { 'proto' },
root_dir = require('lspconfig.util').root_pattern('buf.yaml', '.git'),
},
docs = {
description = [[
https://github.com/bufbuild/buf
buf beta lsp included in the cli itself
buf beta lsp is a Protobuf language server compatible with Buf modules and workspaces
]],
},
}

0 comments on commit 2e92288

Please sign in to comment.