Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
1 change: 1 addition & 0 deletions lsp/ada_ls.lua
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@

local util = require 'lspconfig.util'

---@type vim.lsp.Config
return {
cmd = { 'ada_language_server' },
filetypes = { 'ada' },
Expand Down
1 change: 1 addition & 0 deletions lsp/agda_ls.lua
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

local util = require 'lspconfig.util'

---@type vim.lsp.Config
return {
cmd = { 'als' },
filetypes = { 'agda' },
Expand Down
1 change: 1 addition & 0 deletions lsp/aiken.lua
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
--- [Installation](https://aiken-lang.org/installation-instructions)
---
--- It can be i
---@type vim.lsp.Config
return {
cmd = { 'aiken', 'lsp' },
filetypes = { 'aiken' },
Expand Down
1 change: 1 addition & 0 deletions lsp/air.lua
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
--- Air is an R formatter and language server, written in Rust.
---
--- Refer to the [documentation](https://posit-dev.github.io/air/editors.html) for more details.
---@type vim.lsp.Config
return {
cmd = { 'air', 'language-server' },
filetypes = { 'r' },
Expand Down
1 change: 1 addition & 0 deletions lsp/alloy_ls.lua
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
--- ```
---
--- Alternatively, you may use a syntax plugin like https://github.com/runoshun/vim-alloy.
---@type vim.lsp.Config
return {
cmd = { 'alloy', 'lsp' },
filetypes = { 'alloy' },
Expand Down
1 change: 1 addition & 0 deletions lsp/anakin_language_server.lua
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
---
--- * Initialization: https://github.com/muffinmad/anakin-language-server#initialization-option
--- * Configuration: https://github.com/muffinmad/anakin-language-server#configuration-options
---@type vim.lsp.Config
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Need a blank line above this. Else the ---@type... is part of the generated doc. Plus that's more "correct" anyway since a @brief doc describes the module, not any particular code in the module.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oopsie! I swear, this must be a curse: every small contribution I make here comes with a subtle bug 😭

Follow-up: #4017

return {
cmd = { 'anakinls' },
filetypes = { 'python' },
Expand Down
1 change: 1 addition & 0 deletions lsp/angularls.lua
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ local ng_probe_dirs = vim
end)
:join(',')

---@type vim.lsp.Config
return {
cmd = {
'ngserver',
Expand Down
1 change: 1 addition & 0 deletions lsp/ansiblels.lua
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
--- ```sh
--- npm install -g @ansible/ansible-language-server
--- ```
---@type vim.lsp.Config
return {
cmd = { 'ansible-language-server', '--stdio' },
settings = {
Expand Down
1 change: 1 addition & 0 deletions lsp/antlersls.lua
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
--- ```sh
--- npm install -g antlers-language-server
--- ```
---@type vim.lsp.Config
return {
cmd = { 'antlersls', '--stdio' },
filetypes = { 'html', 'antlers' },
Expand Down
1 change: 1 addition & 0 deletions lsp/arduino_language_server.lua
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@

local util = require 'lspconfig.util'

---@type vim.lsp.Config
return {
filetypes = { 'arduino' },
root_dir = function(bufnr, on_dir)
Expand Down
1 change: 1 addition & 0 deletions lsp/asm_lsp.lua
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
---
--- `asm-lsp` can be installed via cargo:
--- cargo install asm-lsp
---@type vim.lsp.Config
return {
cmd = { 'asm-lsp' },
filetypes = { 'asm', 'vmasm' },
Expand Down
1 change: 1 addition & 0 deletions lsp/ast_grep.lua
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
--- ```sh
--- npm install [-g] @ast-grep/cli
--- ```
---@type vim.lsp.Config
return {
cmd = { 'ast-grep', 'lsp' },
workspace_required = true,
Expand Down
1 change: 1 addition & 0 deletions lsp/astro.lua
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@

local util = require 'lspconfig.util'

---@type vim.lsp.Config
return {
cmd = { 'astro-ls', '--stdio' },
filetypes = { 'astro' },
Expand Down
1 change: 1 addition & 0 deletions lsp/atlas.lua
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@
--- vim.treesitter.language.register('hcl', 'atlas-rule')
--- ```
---
---@type vim.lsp.Config
return {
cmd = { 'atlas', 'tool', 'lsp', '--stdio' },
filetypes = {
Expand Down
1 change: 1 addition & 0 deletions lsp/autohotkey_lsp.lua
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ local function get_autohotkey_path()
return #path > 0 and path or ''
end

---@type vim.lsp.Config
return {
cmd = { 'autohotkey_lsp', '--stdio' },
filetypes = { 'autohotkey' },
Expand Down
1 change: 1 addition & 0 deletions lsp/autotools_ls.lua
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ local util = require 'lspconfig.util'

local root_files = { 'configure.ac', 'Makefile', 'Makefile.am', '*.mk' }

---@type vim.lsp.Config
return {
cmd = { 'autotools-language-server' },
filetypes = { 'config', 'automake', 'make' },
Expand Down
1 change: 1 addition & 0 deletions lsp/awk_ls.lua
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
--- npm install -g awk-language-server
--- ```

---@type vim.lsp.Config
return {
cmd = { 'awk-language-server' },
filetypes = { 'awk' },
Expand Down
1 change: 1 addition & 0 deletions lsp/azure_pipelines_ls.lua
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
--- })
--- ```
--- The Azure Pipelines LSP is a fork of `yaml-language-server` and as such the same settings can be passed to it as `yaml-language-server`.
---@type vim.lsp.Config
return {
cmd = { 'azure-pipelines-language-server', '--stdio' },
filetypes = { 'yaml' },
Expand Down
1 change: 1 addition & 0 deletions lsp/bacon_ls.lua
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@
--- synchronizeAllOpenFilesWaitMillis = 2000,
--- }
--- ```
---@type vim.lsp.Config
return {
cmd = { 'bacon-ls' },
filetypes = { 'rust' },
Expand Down
1 change: 1 addition & 0 deletions lsp/ballerina.lua
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
---
--- The Ballerina language's CLI tool comes with its own language server implementation.
--- The `bal` command line tool must be installed and available in your system's PATH.
---@type vim.lsp.Config
return {
cmd = { 'bal', 'start-language-server' },
filetypes = { 'ballerina' },
Expand Down
3 changes: 2 additions & 1 deletion lsp/basedpyright.lua
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,11 @@ local function set_python_path(path)
else
client.config.settings = vim.tbl_deep_extend('force', client.config.settings, { python = { pythonPath = path } })
end
client.notify('workspace/didChangeConfiguration', { settings = nil })
client:notify('workspace/didChangeConfiguration', { settings = nil })
end
end

---@type vim.lsp.Config
return {
cmd = { 'basedpyright-langserver', '--stdio' },
filetypes = { 'python' },
Expand Down
1 change: 1 addition & 0 deletions lsp/bashls.lua
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
--- ```
---
--- Language server for bash, written using tree sitter in typescript.
---@type vim.lsp.Config
return {
cmd = { 'bash-language-server', 'start' },
settings = {
Expand Down
1 change: 1 addition & 0 deletions lsp/basics_ls.lua
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
--- ```sh
--- npm install -g basics-language-server
--- ```
---@type vim.lsp.Config
return {
cmd = { 'basics-language-server' },
settings = {
Expand Down
1 change: 1 addition & 0 deletions lsp/bazelrc_lsp.lua
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
--- },
--- }
--- ```
---@type vim.lsp.Config
return {
cmd = { 'bazelrc-lsp', 'lsp' },
filetypes = { 'bazelrc' },
Expand Down
1 change: 1 addition & 0 deletions lsp/beancount.lua
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
--- https://github.com/polarmutex/beancount-language-server#installation
---
--- See https://github.com/polarmutex/beancount-language-server#configuration for configuration options
---@type vim.lsp.Config
return {
cmd = { 'beancount-language-server', '--stdio' },
filetypes = { 'beancount', 'bean' },
Expand Down
1 change: 1 addition & 0 deletions lsp/bicep.lua
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
--- && rm -rf /usr/local/bin/bicep-langserver \
--- && unzip -d /usr/local/bin/bicep-langserver bicep-langserver.zip)
--- ```
---@type vim.lsp.Config
return {
filetypes = { 'bicep', 'bicep-params' },
root_markers = { '.git' },
Expand Down
5 changes: 3 additions & 2 deletions lsp/biome.lua
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@

local util = require 'lspconfig.util'

---@type vim.lsp.Config
return {
cmd = function(dispatchers, config)
local cmd = 'biome'
Expand Down Expand Up @@ -46,7 +47,7 @@ return {
local project_root_markers = { 'package-lock.json', 'yarn.lock', 'pnpm-lock.yaml', 'bun.lockb', 'bun.lock' }
local project_root = vim.fs.root(bufnr, project_root_markers)
if not project_root then
return nil
return
end

-- We know that the buffer is using Biome if it has a config file
Expand All @@ -62,7 +63,7 @@ return {
stop = vim.fs.dirname(project_root),
})[1]
if not is_buffer_using_biome then
return nil
return
end

on_dir(project_root)
Expand Down
1 change: 1 addition & 0 deletions lsp/bitbake_language_server.lua
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---@brief
---
--- 🛠️ bitbake language server
---@type vim.lsp.Config
return {
cmd = { 'bitbake-language-server' },
filetypes = { 'bitbake' },
Expand Down
1 change: 1 addition & 0 deletions lsp/blueprint_ls.lua
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
---
--- Language server for the blueprint markup language, written in python and part
--- of the blueprint-compiler.
---@type vim.lsp.Config
return {
cmd = { 'blueprint-compiler', 'lsp' },
cmd_env = {
Expand Down
1 change: 1 addition & 0 deletions lsp/bqls.lua
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
--- ```sh
--- $ go install github.com/kitagry/bqls@latest
--- ```
---@type vim.lsp.Config
return {
cmd = { 'bqls' },
filetypes = { 'sql' },
Expand Down
1 change: 1 addition & 0 deletions lsp/bright_script.lua
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
--- ```sh
--- npm install -g brighterscript
--- ```
---@type vim.lsp.Config
return {
cmd = { 'bsc', '--lsp', '--stdio' },
filetypes = { 'brs' },
Expand Down
1 change: 1 addition & 0 deletions lsp/bsl_ls.lua
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
---
--- Language Server Protocol implementation for 1C (BSL) - 1C:Enterprise 8 and OneScript languages.

---@type vim.lsp.Config
return {
filetypes = { 'bsl', 'os' },
root_markers = { '.git' },
Expand Down
1 change: 1 addition & 0 deletions lsp/buck2.lua
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
--- ```
--- vim.cmd [[ autocmd BufRead,BufNewFile *.bxl,BUCK,TARGETS set filetype=bzl ]]
--- ```
---@type vim.lsp.Config
return {
cmd = { 'buck2', 'lsp' },
filetypes = { 'bzl' },
Expand Down
1 change: 1 addition & 0 deletions lsp/buddy_ls.lua
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
--- The Language Server for the buddy-mlir, a drop-in replacement for mlir-lsp-server,
--- supporting new dialects defined in buddy-mlir.
--- `buddy-lsp-server` can be installed at the buddy-mlir repository (buddy-compiler/buddy-mlir)
---@type vim.lsp.Config
return {
cmd = { 'buddy-lsp-server' },
filetypes = { 'mlir' },
Expand Down
1 change: 1 addition & 0 deletions lsp/buf_ls.lua
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
---
--- buf beta lsp is a Protobuf language server compatible with Buf modules and workspaces

---@type vim.lsp.Config
return {
cmd = { 'buf', 'beta', 'lsp', '--timeout=0', '--log-format=text' },
filetypes = { 'proto' },
Expand Down
1 change: 1 addition & 0 deletions lsp/bufls.lua
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
--- ```
---
--- bufls is a Protobuf language server compatible with Buf modules and workspaces
---@type vim.lsp.Config
return {
cmd = { 'bufls', 'serve' },
filetypes = { 'proto' },
Expand Down
1 change: 1 addition & 0 deletions lsp/bzl.lua
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
--- https://docs.stack.build/docs/cli/installation
---
--- https://docs.stack.build/docs/vscode/starlark-language-server
---@type vim.lsp.Config
return {
cmd = { 'bzl', 'lsp', 'serve' },
filetypes = { 'bzl' },
Expand Down
1 change: 1 addition & 0 deletions lsp/c3_lsp.lua
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
--- https://github.com/pherrymason/c3-lsp
---
--- Language Server for c3.
---@type vim.lsp.Config
return {
cmd = { 'c3lsp' },
root_markers = { 'project.json', 'manifest.json', '.git' },
Expand Down
1 change: 1 addition & 0 deletions lsp/cairo_ls.lua
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
--- ```
---
--- *cairo-language-server is still under active development, some features might not work yet !*
---@type vim.lsp.Config
return {
init_options = { hostInfo = 'neovim' },
cmd = { 'scarb', 'cairo-language-server', '/C', '--node-ipc' },
Expand Down
1 change: 1 addition & 0 deletions lsp/ccls.lua
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ local function switch_source_header(client, bufnr)
end, bufnr)
end

---@type vim.lsp.Config
return {
cmd = { 'ccls' },
filetypes = { 'c', 'cpp', 'objc', 'objcpp', 'cuda' },
Expand Down
1 change: 1 addition & 0 deletions lsp/cds_lsp.lua
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
--- ```sh
--- npm i -g @sap/cds-lsp
--- ```
---@type vim.lsp.Config
return {
cmd = { 'cds-lsp', '--stdio' },
filetypes = { 'cds' },
Expand Down
1 change: 1 addition & 0 deletions lsp/circom-lsp.lua
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
--- [Circom Language Server](https://github.com/rubydusa/circom-lsp)
---
--- `circom-lsp`, the language server for the Circom language.
---@type vim.lsp.Config
return {
cmd = { 'circom-lsp' },
filetypes = { 'circom' },
Expand Down
4 changes: 1 addition & 3 deletions lsp/clangd.lua
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ end
---@class ClangdInitializeResult: lsp.InitializeResult
---@field offsetEncoding? string

---@type vim.lsp.Config
return {
cmd = { 'clangd' },
filetypes = { 'c', 'cpp', 'objc', 'objcpp', 'cuda' },
Expand All @@ -81,15 +82,12 @@ return {
},
offsetEncoding = { 'utf-8', 'utf-16' },
},
---@param client vim.lsp.Client
---@param init_result ClangdInitializeResult
on_init = function(client, init_result)
if init_result.offsetEncoding then
client.offset_encoding = init_result.offsetEncoding
end
end,
---@param client vim.lsp.Client
---@param bufnr integer
on_attach = function(client, bufnr)
vim.api.nvim_buf_create_user_command(bufnr, 'LspClangdSwitchSourceHeader', function()
switch_source_header(bufnr, client)
Expand Down
1 change: 1 addition & 0 deletions lsp/clarinet.lua
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
--- https://github.com/hirosystems/clarinet
---
--- Clarinet is the fastest way to build, test, and deploy smart contracts on the Stacks blockchain.
---@type vim.lsp.Config
return {
cmd = { 'clarinet', 'lsp' },
filetypes = { 'clar', 'clarity' },
Expand Down
1 change: 1 addition & 0 deletions lsp/clojure_lsp.lua
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
--- https://github.com/clojure-lsp/clojure-lsp
---
--- Clojure Language Server
---@type vim.lsp.Config
return {
cmd = { 'clojure-lsp' },
filetypes = { 'clojure', 'edn' },
Expand Down
Loading