diff options
| author | Justin M. Keyes <justinkz@gmail.com> | 2025-04-12 19:40:01 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-04-12 19:40:01 -0700 |
| commit | ecb74c22b4a6c41162153f77e73d4ef645fedfa0 (patch) | |
| tree | af9ad45b7af4c1b3fa736a359832c86fb88743c3 /doc | |
| parent | feat(typos-lsp): support pyproject.toml and Cargo.toml #3707 (diff) | |
| download | nvim-lspconfig-ecb74c22b4a6c41162153f77e73d4ef645fedfa0.tar nvim-lspconfig-ecb74c22b4a6c41162153f77e73d4ef645fedfa0.tar.gz nvim-lspconfig-ecb74c22b4a6c41162153f77e73d4ef645fedfa0.tar.bz2 nvim-lspconfig-ecb74c22b4a6c41162153f77e73d4ef645fedfa0.tar.lz nvim-lspconfig-ecb74c22b4a6c41162153f77e73d4ef645fedfa0.tar.xz nvim-lspconfig-ecb74c22b4a6c41162153f77e73d4ef645fedfa0.tar.zst nvim-lspconfig-ecb74c22b4a6c41162153f77e73d4ef645fedfa0.zip | |
fix(docs): docgen.lua reads from `lua/*.lua` #3708
Problem:
Since configs now live in `lsp/`, the docgen needs to be updated.
Solution:
Read the configs from `lsp/`. Parse the `@brief` docstring to get the
docs.
Diffstat (limited to 'doc')
| -rw-r--r-- | doc/configs.md | 3528 | ||||
| -rw-r--r-- | doc/configs.txt | 4124 |
2 files changed, 2955 insertions, 4697 deletions
diff --git a/doc/configs.md b/doc/configs.md index 6880a1b4..288df071 100644 --- a/doc/configs.md +++ b/doc/configs.md @@ -10,14 +10,11 @@ Nvim by running `:help lspconfig-all`. - [air](#air) - [alloy_ls](#alloy_ls) - [anakin_language_server](#anakin_language_server) -- [angularls](#angularls) - [ansiblels](#ansiblels) - [antlersls](#antlersls) -- [apex_ls](#apex_ls) - [arduino_language_server](#arduino_language_server) - [asm_lsp](#asm_lsp) - [ast_grep](#ast_grep) -- [astro](#astro) - [atlas](#atlas) - [autohotkey_lsp](#autohotkey_lsp) - [autotools_ls](#autotools_ls) @@ -31,12 +28,9 @@ Nvim by running `:help lspconfig-all`. - [bazelrc_lsp](#bazelrc_lsp) - [beancount](#beancount) - [bicep](#bicep) -- [biome](#biome) - [bitbake_language_server](#bitbake_language_server) -- [bitbake_ls](#bitbake_ls) - [blueprint_ls](#blueprint_ls) - [bqls](#bqls) -- [bqnlsp](#bqnlsp) - [bright_script](#bright_script) - [bsl_ls](#bsl_ls) - [buck2](#buck2) @@ -45,9 +39,7 @@ Nvim by running `:help lspconfig-all`. - [bufls](#bufls) - [bzl](#bzl) - [c3_lsp](#c3_lsp) -- [cadence](#cadence) - [cairo_ls](#cairo_ls) -- [ccls](#ccls) - [cds_lsp](#cds_lsp) - [circom-lsp](#circom-lsp) - [clangd](#clangd) @@ -55,7 +47,6 @@ Nvim by running `:help lspconfig-all`. - [clojure_lsp](#clojure_lsp) - [cmake](#cmake) - [cobol_ls](#cobol_ls) -- [codeqlls](#codeqlls) - [coffeesense](#coffeesense) - [contextive](#contextive) - [coq_lsp](#coq_lsp) @@ -74,7 +65,6 @@ Nvim by running `:help lspconfig-all`. - [dartls](#dartls) - [dcmls](#dcmls) - [debputy](#debputy) -- [delphi_ls](#delphi_ls) - [denols](#denols) - [dhall_lsp_server](#dhall_lsp_server) - [diagnosticls](#diagnosticls) @@ -85,12 +75,10 @@ Nvim by running `:help lspconfig-all`. - [dolmenls](#dolmenls) - [dotls](#dotls) - [dprint](#dprint) -- [drools_lsp](#drools_lsp) - [ds_pinyin_lsp](#ds_pinyin_lsp) - [dts_lsp](#dts_lsp) - [earthlyls](#earthlyls) - [ecsact](#ecsact) -- [efm](#efm) - [elixirls](#elixirls) - [elmls](#elmls) - [elp](#elp) @@ -100,7 +88,6 @@ Nvim by running `:help lspconfig-all`. - [erg_language_server](#erg_language_server) - [erlangls](#erlangls) - [esbonio](#esbonio) -- [eslint](#eslint) - [facility_language_server](#facility_language_server) - [fennel_language_server](#fennel_language_server) - [fennel_ls](#fennel_ls) @@ -115,14 +102,12 @@ Nvim by running `:help lspconfig-all`. - [futhark_lsp](#futhark_lsp) - [gdscript](#gdscript) - [gdshader_lsp](#gdshader_lsp) -- [gh_actions_ls](#gh_actions_ls) - [ghcide](#ghcide) - [ghdl_ls](#ghdl_ls) - [ginko_ls](#ginko_ls) - [gitlab_ci_ls](#gitlab_ci_ls) - [glasgow](#glasgow) - [gleam](#gleam) -- [glint](#glint) - [glsl_analyzer](#glsl_analyzer) - [glslls](#glslls) - [golangci_lint_ls](#golangci_lint_ls) @@ -133,7 +118,6 @@ Nvim by running `:help lspconfig-all`. - [groovyls](#groovyls) - [guile_ls](#guile_ls) - [harper_ls](#harper_ls) -- [haxe_language_server](#haxe_language_server) - [hdl_checker](#hdl_checker) - [helm_ls](#helm_ls) - [hhvm](#hhvm) @@ -154,7 +138,6 @@ Nvim by running `:help lspconfig-all`. - [jinja_lsp](#jinja_lsp) - [jqls](#jqls) - [jsonls](#jsonls) -- [jsonnet_ls](#jsonnet_ls) - [julials](#julials) - [just](#just) - [kcl](#kcl) @@ -162,7 +145,6 @@ Nvim by running `:help lspconfig-all`. - [kotlin_language_server](#kotlin_language_server) - [kulala_ls](#kulala_ls) - [lean3ls](#lean3ls) -- [leanls](#leanls) - [lelwel_ls](#lelwel_ls) - [lemminx](#lemminx) - [lexical](#lexical) @@ -176,8 +158,6 @@ Nvim by running `:help lspconfig-all`. - [markdown_oxide](#markdown_oxide) - [marko-js](#marko-js) - [marksman](#marksman) -- [matlab_ls](#matlab_ls) -- [mdx_analyzer](#mdx_analyzer) - [mesonlsp](#mesonlsp) - [metals](#metals) - [millet](#millet) @@ -208,12 +188,9 @@ Nvim by running `:help lspconfig-all`. - [ocamlls](#ocamlls) - [ocamllsp](#ocamllsp) - [ols](#ols) -- [omnisharp](#omnisharp) - [opencl_ls](#opencl_ls) -- [openedge_ls](#openedge_ls) - [openscad_ls](#openscad_ls) - [openscad_lsp](#openscad_lsp) -- [oxlint](#oxlint) - [pact_ls](#pact_ls) - [pasls](#pasls) - [pbls](#pbls) @@ -228,7 +205,6 @@ Nvim by running `:help lspconfig-all`. - [please](#please) - [poryscript_pls](#poryscript_pls) - [postgres_lsp](#postgres_lsp) -- [powershell_es](#powershell_es) - [prismals](#prismals) - [prolog_ls](#prolog_ls) - [prosemd_lsp](#prosemd_lsp) @@ -249,7 +225,6 @@ Nvim by running `:help lspconfig-all`. - [reason_ls](#reason_ls) - [regal](#regal) - [regols](#regols) -- [relay_lsp](#relay_lsp) - [remark_ls](#remark_ls) - [rescriptls](#rescriptls) - [rls](#rls) @@ -287,7 +262,6 @@ Nvim by running `:help lspconfig-all`. - [somesass_ls](#somesass_ls) - [sorbet](#sorbet) - [sourcekit](#sourcekit) -- [sourcery](#sourcery) - [spectral](#spectral) - [spyglassmc_language_server](#spyglassmc_language_server) - [sqlls](#sqlls) @@ -308,7 +282,6 @@ Nvim by running `:help lspconfig-all`. - [syntax_tree](#syntax_tree) - [systemd_ls](#systemd_ls) - [tabby_ml](#tabby_ml) -- [tailwindcss](#tailwindcss) - [taplo](#taplo) - [tblgen_lsp_server](#tblgen_lsp_server) - [teal_ls](#teal_ls) @@ -342,8 +315,6 @@ Nvim by running `:help lspconfig-all`. - [vacuum](#vacuum) - [vala_ls](#vala_ls) - [vale_ls](#vale_ls) -- [vdmj](#vdmj) -- [vectorcode_server](#vectorcode_server) - [verible](#verible) - [veridian](#veridian) - [veryl_ls](#veryl_ls) @@ -351,7 +322,6 @@ Nvim by running `:help lspconfig-all`. - [vimls](#vimls) - [visualforce_ls](#visualforce_ls) - [vls](#vls) -- [volar](#volar) - [vscoqtop](#vscoqtop) - [vtsls](#vtsls) - [vuels](#vuels) @@ -363,7 +333,6 @@ Nvim by running `:help lspconfig-all`. - [ziggy](#ziggy) - [ziggy_schema](#ziggy_schema) - [zk](#zk) -- [zls](#zls) ## ada_ls @@ -372,18 +341,17 @@ https://github.com/AdaCore/ada_language_server Installation instructions can be found [here](https://github.com/AdaCore/ada_language_server#Install). Workspace-specific [settings](https://github.com/AdaCore/ada_language_server/blob/master/doc/settings.md) such as `projectFile` can be provided in a `.als.json` file at the root of the workspace. - -Alternatively, configuration may be passed as a "settings" object to `ada_ls.setup{}`: +Alternatively, configuration may be passed as a "settings" object to `vim.lsp.config('ada_ls', {})`: ```lua -require('lspconfig').ada_ls.setup{ +vim.lsp.config('ada_ls', { settings = { ada = { projectFile = "project.gpr"; scenarioVariables = { ... }; } } -} +}) ``` Snippet to enable the language server: @@ -400,7 +368,7 @@ Default config: ```lua { "ada" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ada_ls.lua:4](../lua/lspconfig/configs/ada_ls.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/ada_ls.lua:22](../lsp/ada_ls.lua#L22) --- @@ -424,8 +392,7 @@ Default config: ```lua { "agda" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/agda_ls.lua:4](../lua/lspconfig/configs/agda_ls.lua#L4) -- `single_file_support` : `true` +- `root_dir` source (use "gF" to open): [../lsp/agda_ls.lua:8](../lsp/agda_ls.lua#L8) --- @@ -452,7 +419,10 @@ Default config: ```lua { "aiken" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/aiken.lua:4](../lua/lspconfig/configs/aiken.lua#L4) +- `root_markers` : + ```lua + { "aiken.toml", ".git" } + ``` --- @@ -478,8 +448,10 @@ Default config: ```lua { "r" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/air.lua:2](../lua/lspconfig/configs/air.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "air.toml", ".air.toml", ".git" } + ``` --- @@ -521,8 +493,10 @@ Default config: ```lua { "alloy" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/alloy_ls.lua:2](../lua/lspconfig/configs/alloy_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -551,7 +525,10 @@ Default config: ```lua { "python" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/anakin_language_server.lua:4](../lua/lspconfig/configs/anakin_language_server.lua#L4) +- `root_markers` : + ```lua + { "pyproject.toml", "setup.py", "setup.cfg", "requirements.txt", "Pipfile", ".git" } + ``` - `settings` : ```lua { @@ -560,45 +537,6 @@ Default config: } } ``` -- `single_file_support` : `true` - ---- - -## angularls - -https://github.com/angular/vscode-ng-language-service - -`angular-language-server` can be installed via npm `npm install -g @angular/language-server`. - -Note, that if you override the default `cmd`, you must also update `on_new_config` to set `new_config.cmd` during startup. - -```lua -local project_library_path = "/path/to/project/lib" -local cmd = {"ngserver", "--stdio", "--tsProbeLocations", project_library_path , "--ngProbeLocations", project_library_path} - -require'lspconfig'.angularls.setup{ - cmd = cmd, - on_new_config = function(new_config,new_root_dir) - new_config.cmd = cmd - end, -} -``` - -Snippet to enable the language server: -```lua -require'lspconfig'.angularls.setup{} -``` - -Default config: -- `cmd` : - ```lua - { "ngserver", "--stdio", "--tsProbeLocations", "", "--ngProbeLocations", "", "--angularCoreVersion", "" } - ``` -- `filetypes` : - ```lua - { "typescript", "html", "typescriptreact", "typescript.tsx", "htmlangular" } - ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/angularls.lua:41](../lua/lspconfig/configs/angularls.lua#L41) --- @@ -628,7 +566,10 @@ Default config: ```lua { "yaml.ansible" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ansiblels.lua:4](../lua/lspconfig/configs/ansiblels.lua#L4) +- `root_markers` : + ```lua + { "ansible.cfg", ".ansible-lint" } + ``` - `settings` : ```lua { @@ -652,7 +593,6 @@ Default config: } } ``` -- `single_file_support` : `true` --- @@ -679,39 +619,10 @@ Default config: ```lua { "html", "antlers" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/antlersls.lua:4](../lua/lspconfig/configs/antlersls.lua#L4) - ---- - -## apex_ls - -https://github.com/forcedotcom/salesforcedx-vscode - -Language server for Apex. - -For manual installation, download the JAR file from the [VSCode -extension](https://github.com/forcedotcom/salesforcedx-vscode/tree/develop/packages/salesforcedx-vscode-apex). - -```lua -require'lspconfig'.apex_ls.setup { - apex_jar_path = '/path/to/apex-jorje-lsp.jar', - apex_enable_semantic_errors = false, -- Whether to allow Apex Language Server to surface semantic errors - apex_enable_completion_statistics = false, -- Whether to allow Apex Language Server to collect telemetry on code completion usage -} -``` - -Snippet to enable the language server: -```lua -require'lspconfig'.apex_ls.setup{} -``` - -Default config: -- `filetypes` : +- `root_markers` : ```lua - { "apexcode" } + { "composer.json" } ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/apex_ls.lua:4](../lua/lspconfig/configs/apex_ls.lua#L4) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/apex_ls.lua:4](../lua/lspconfig/configs/apex_ls.lua#L4) --- @@ -810,7 +721,7 @@ Default config: ```lua { "arduino" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/arduino_language_server.lua:4](../lua/lspconfig/configs/arduino_language_server.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/arduino_language_server.lua:72](../lsp/arduino_language_server.lua#L72) --- @@ -837,8 +748,10 @@ Default config: ```lua { "asm", "vmasm" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/asm_lsp.lua:2](../lua/lspconfig/configs/asm_lsp.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".asm-lsp.toml", ".git" } + ``` --- @@ -866,41 +779,10 @@ Default config: ```lua { "c", "cpp", "rust", "go", "java", "python", "javascript", "typescript", "html", "css", "kotlin", "dart", "lua" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ast_grep.lua:4](../lua/lspconfig/configs/ast_grep.lua#L4) - ---- - -## astro - -https://github.com/withastro/language-tools/tree/main/packages/language-server - -`astro-ls` can be installed via `npm`: -```sh -npm install -g @astrojs/language-server -``` - -Snippet to enable the language server: -```lua -require'lspconfig'.astro.setup{} -``` - -Default config: -- `cmd` : - ```lua - { "astro-ls", "--stdio" } - ``` -- `filetypes` : +- `root_markers` : ```lua - { "astro" } - ``` -- `init_options` : - ```lua - { - typescript = {} - } + { "sgconfig.yaml", "sgconfig.yml" } ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/astro.lua:9](../lua/lspconfig/configs/astro.lua#L9) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/astro.lua:9](../lua/lspconfig/configs/astro.lua#L9) --- @@ -970,8 +852,10 @@ Default config: ```lua { "atlas-*" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/atlas.lua:4](../lua/lspconfig/configs/atlas.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "atlas.hcl" } + ``` --- @@ -987,7 +871,6 @@ require'lspconfig'.autohotkey_lsp.setup{} ``` Default config: -- `autostart` : `true` - `cmd` : ```lua { "autohotkey_lsp", "--stdio" } @@ -1034,8 +917,10 @@ Default config: locale = "en-us" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/autohotkey_lsp.lua:8](../lua/lspconfig/configs/autohotkey_lsp.lua#L8) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "package.json" } + ``` --- @@ -1064,8 +949,7 @@ Default config: ```lua { "config", "automake", "make" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/autotools_ls.lua:6](../lua/lspconfig/configs/autotools_ls.lua#L6) -- `single_file_support` : `true` +- `root_dir` source (use "gF" to open): [../lsp/autotools_ls.lua:15](../lsp/autotools_ls.lua#L15) --- @@ -1092,7 +976,6 @@ Default config: ```lua { "awk" } ``` -- `single_file_support` : `true` --- @@ -1110,7 +993,7 @@ npm install -g azure-pipelines-language-server By default `azure-pipelines-ls` will only work in files named `azure-pipelines.yml`, this can be changed by providing additional settings like so: ```lua -require("lspconfig").azure_pipelines_ls.setup { +vim.lsp.config('azure_pipelines_ls', { ... -- other configuration for setup {} settings = { yaml = { @@ -1124,7 +1007,7 @@ require("lspconfig").azure_pipelines_ls.setup { }, }, }, -} +}) ``` 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`. @@ -1142,12 +1025,14 @@ Default config: ```lua { "yaml" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/azure_pipelines_ls.lua:4](../lua/lspconfig/configs/azure_pipelines_ls.lua#L4) +- `root_markers` : + ```lua + { "azure-pipelines.yml" } + ``` - `settings` : ```lua {} ``` -- `single_file_support` : `true` --- @@ -1209,8 +1094,10 @@ Default config: ```lua {} ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/bacon_ls.lua:4](../lua/lspconfig/configs/bacon_ls.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".bacon-locations", "Cargo.toml" } + ``` --- @@ -1218,8 +1105,8 @@ Default config: Ballerina language server -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. + 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. Snippet to enable the language server: ```lua @@ -1235,7 +1122,10 @@ Default config: ```lua { "ballerina" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ballerina.lua:4](../lua/lspconfig/configs/ballerina.lua#L4) +- `root_markers` : + ```lua + { "Ballerina.toml" } + ``` --- @@ -1250,10 +1140,6 @@ Snippet to enable the language server: require'lspconfig'.basedpyright.setup{} ``` -Commands: -- PyrightOrganizeImports: Organize Imports -- PyrightSetPythonPath: Reconfigure basedpyright with the provided python path - Default config: - `cmd` : ```lua @@ -1263,7 +1149,11 @@ Default config: ```lua { "python" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/basedpyright.lua:44](../lua/lspconfig/configs/basedpyright.lua#L44) +- `on_attach` source (use "gF" to open): [../lsp/basedpyright.lua:36](../lsp/basedpyright.lua#L36) +- `root_markers` : + ```lua + { "pyproject.toml", "setup.py", "setup.cfg", "requirements.txt", "Pipfile", "pyrightconfig.json", ".git" } + ``` - `settings` : ```lua { @@ -1276,7 +1166,6 @@ Default config: } } ``` -- `single_file_support` : `true` --- @@ -1305,7 +1194,10 @@ Default config: ```lua { "bash", "sh" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/bashls.lua:2](../lua/lspconfig/configs/bashls.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua { @@ -1314,7 +1206,6 @@ Default config: } } ``` -- `single_file_support` : `true` --- @@ -1354,7 +1245,6 @@ Default config: } } ``` -- `single_file_support` : `true` --- @@ -1388,7 +1278,10 @@ Default config: ```lua { "bazelrc" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/bazelrc_lsp.lua:4](../lua/lspconfig/configs/bazelrc_lsp.lua#L4) +- `root_markers` : + ```lua + { "WORKSPACE", "WORKSPACE.bazel", "MODULE.bazel" } + ``` --- @@ -1416,8 +1309,10 @@ Default config: ```lua {} ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/beancount.lua:2](../lua/lspconfig/configs/beancount.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -1441,10 +1336,10 @@ vim.cmd [[ autocmd BufNewFile,BufRead *.bicep set filetype=bicep ]] ```lua local bicep_lsp_bin = "/path/to/bicep-langserver/Bicep.LangServer.dll" -require'lspconfig'.bicep.setup{ +vim.lsp.config('bicep', { cmd = { "dotnet", bicep_lsp_bin }; ... -} +}) ``` To download the latest release and place in /usr/local/bin/bicep-langserver: @@ -1469,36 +1364,10 @@ Default config: ```lua {} ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/bicep.lua:2](../lua/lspconfig/configs/bicep.lua#L2) - ---- - -## biome - -https://biomejs.dev - -Toolchain of the web. [Successor of Rome](https://biomejs.dev/blog/annoucing-biome). - -```sh -npm install [-g] @biomejs/biome -``` - -Snippet to enable the language server: -```lua -require'lspconfig'.biome.setup{} -``` - -Default config: -- `cmd` : - ```lua - { "biome", "lsp-proxy" } - ``` -- `filetypes` : +- `root_markers` : ```lua - { "astro", "css", "graphql", "javascript", "javascriptreact", "json", "jsonc", "svelte", "typescript", "typescript.tsx", "typescriptreact", "vue" } + { ".git" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/biome.lua:4](../lua/lspconfig/configs/biome.lua#L4) -- `single_file_support` : `false` --- @@ -1520,39 +1389,10 @@ Default config: ```lua { "bitbake" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/bitbake_language_server.lua:2](../lua/lspconfig/configs/bitbake_language_server.lua#L2) - ---- - -## bitbake_ls - -https://github.com/yoctoproject/vscode-bitbake/tree/staging/server -https://www.npmjs.com/package/language-server-bitbake - -Official Bitbake Language Server for the Yocto Project. - -Can be installed from npm or github. - -``` -npm install -g language-server-bitbake -``` - -Snippet to enable the language server: -```lua -require'lspconfig'.bitbake_ls.setup{} -``` - -Default config: -- `cmd` : - ```lua - { "language-server-bitbake", "--stdio" } - ``` -- `filetypes` : +- `root_markers` : ```lua - { "bitbake" } + { ".git" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/bitbake_ls.lua:2](../lua/lspconfig/configs/bitbake_ls.lua#L2) -- `single_file_support` : `false` --- @@ -1585,8 +1425,10 @@ Default config: ```lua { "blueprint" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/blueprint_ls.lua:2](../lua/lspconfig/configs/blueprint_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -1614,44 +1456,14 @@ Default config: ```lua { "sql" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/bqls.lua:2](../lua/lspconfig/configs/bqls.lua#L2) -- `settings` : - ```lua - {} - ``` -- `single_file_support` : `true` - ---- - -## bqnlsp - -https://git.sr.ht/~detegr/bqnlsp - - -`bqnlsp`, a language server for BQN. - -The binary depends on the shared library of [CBQN](https://github.com/dzaima/CBQN) `libcbqn.so`. -If CBQN is installed system-wide (using `sudo make install` in its source directory) and `bqnlsp` errors that it can't find the shared library, update the linker cache by executing `sudo ldconfig`. -If CBQN has been installed in a non-standard directory or can't be installed globally pass `libcbqnPath = '/path/to/CBQN'` to the setup function. -This will set the environment variables `LD_LIBRARY_PATH` (Linux) or `DYLD_LIBRARY_PATH` (macOS) to the provided path. - -Snippet to enable the language server: -```lua -require'lspconfig'.bqnlsp.setup{} -``` - -Default config: -- `cmd` : +- `root_markers` : ```lua - { "bqnlsp" } + { ".git" } ``` -- `filetypes` : +- `settings` : ```lua - { "bqn" } + {} ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/bqnlsp.lua:14](../lua/lspconfig/configs/bqnlsp.lua#L14) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/bqnlsp.lua:14](../lua/lspconfig/configs/bqnlsp.lua#L14) -- `single_file_support` : `true` --- @@ -1678,7 +1490,10 @@ Default config: ```lua { "brs" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/bright_script.lua:4](../lua/lspconfig/configs/bright_script.lua#L4) +- `root_markers` : + ```lua + { "makefile", "Makefile", ".git" } + ``` - `single_file_support` : `true` --- @@ -1687,7 +1502,7 @@ Default config: https://github.com/1c-syntax/bsl-language-server - Language Server Protocol implementation for 1C (BSL) - 1C:Enterprise 8 and OneScript languages. +Language Server Protocol implementation for 1C (BSL) - 1C:Enterprise 8 and OneScript languages. Snippet to enable the language server: ```lua @@ -1699,7 +1514,10 @@ Default config: ```lua { "bsl", "os" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/bsl_ls.lua:2](../lua/lspconfig/configs/bsl_ls.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -1729,7 +1547,10 @@ Default config: ```lua { "bzl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/buck2.lua:4](../lua/lspconfig/configs/buck2.lua#L4) +- `root_markers` : + ```lua + { ".buckconfig" } + ``` --- @@ -1754,18 +1575,16 @@ Default config: ```lua { "mlir" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/buddy_ls.lua:2](../lua/lspconfig/configs/buddy_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- ## buf_ls -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 Snippet to enable the language server: ```lua @@ -1781,7 +1600,10 @@ Default config: ```lua { "proto" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/buf_ls.lua:2](../lua/lspconfig/configs/buf_ls.lua#L2) +- `root_markers` : + ```lua + { "buf.yaml", ".git" } + ``` --- @@ -1810,7 +1632,10 @@ Default config: ```lua { "proto" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/bufls.lua:4](../lua/lspconfig/configs/bufls.lua#L4) +- `root_markers` : + ```lua + { "buf.work.yaml", ".git" } + ``` --- @@ -1836,7 +1661,10 @@ Default config: ```lua { "bzl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/bzl.lua:4](../lua/lspconfig/configs/bzl.lua#L4) +- `root_markers` : + ```lua + { "WORKSPACE", "WORKSPACE.bazel" } + ``` --- @@ -1860,43 +1688,10 @@ Default config: ```lua { "c3", "c3i" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/c3_lsp.lua:4](../lua/lspconfig/configs/c3_lsp.lua#L4) - ---- - -## cadence - -[Cadence Language Server](https://github.com/onflow/cadence-tools/tree/master/languageserver) -using the [flow-cli](https://developers.flow.com/tools/flow-cli). - -The `flow` command from flow-cli must be available. For install instructions see -[the docs](https://developers.flow.com/tools/flow-cli/install#install-the-flow-cli) or the -[Github page](https://github.com/onflow/flow-cli). - -By default the configuration is taken from the closest `flow.json` or the `flow.json` in the users home directory. - -Snippet to enable the language server: -```lua -require'lspconfig'.cadence.setup{} -``` - -Default config: -- `cmd` : +- `root_markers` : ```lua - { "flow", "cadence", "language-server" } + { "project.json", "manifest.json", ".git" } ``` -- `filetypes` : - ```lua - { "cdc" } - ``` -- `init_options` : - ```lua - { - numberOfAccounts = "1" - } - ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/cadence.lua:4](../lua/lspconfig/configs/cadence.lua#L4) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/cadence.lua:4](../lua/lspconfig/configs/cadence.lua#L4) --- @@ -1904,14 +1699,14 @@ Default config: [Cairo Language Server](https://github.com/starkware-libs/cairo/tree/main/crates/cairo-lang-language-server) -First, install Cairo following [this tutorial](https://book.cairo-lang.org/ch01-01-installation.html) + First, install Cairo following [this tutorial](https://book.cairo-lang.org/ch01-01-installation.html) -Then enable Cairo Language Server in your Lua configuration. -```lua -require'lspconfig'.cairo_ls.setup{} -``` + Then enable Cairo Language Server in your Lua configuration. + ```lua + vim.lsp.enable('cairo_ls') + ``` -*cairo-language-server is still under active development, some features might not work yet !* + *cairo-language-server is still under active development, some features might not work yet !* Snippet to enable the language server: ```lua @@ -1933,59 +1728,10 @@ Default config: hostInfo = "neovim" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/cairo_ls.lua:4](../lua/lspconfig/configs/cairo_ls.lua#L4) - ---- - -## ccls - -https://github.com/MaskRay/ccls/wiki - -ccls relies on a [JSON compilation database](https://clang.llvm.org/docs/JSONCompilationDatabase.html) specified -as compile_commands.json or, for simpler projects, a .ccls. -For details on how to automatically generate one using CMake look [here](https://cmake.org/cmake/help/latest/variable/CMAKE_EXPORT_COMPILE_COMMANDS.html). Alternatively, you can use [Bear](https://github.com/rizsotto/Bear). - -Customization options are passed to ccls at initialization time via init_options, a list of available options can be found [here](https://github.com/MaskRay/ccls/wiki/Customization#initialization-options). For example: - -```lua -local lspconfig = require'lspconfig' -lspconfig.ccls.setup { - init_options = { - compilationDatabaseDirectory = "build"; - index = { - threads = 0; - }; - clang = { - excludeArgs = { "-frounding-math"} ; - }; - } -} - -``` - -Snippet to enable the language server: -```lua -require'lspconfig'.ccls.setup{} -``` - -Commands: -- CclsSwitchSourceHeader: Switch between source/header - -Default config: -- `cmd` : - ```lua - { "ccls" } - ``` -- `filetypes` : +- `root_markers` : ```lua - { "c", "cpp", "objc", "objcpp", "cuda" } + { "Scarb.toml", "cairo_project.toml", ".git" } ``` -- `offset_encoding` : - ```lua - "utf-32" - ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ccls.lua:24](../lua/lspconfig/configs/ccls.lua#L24) -- `single_file_support` : `false` --- @@ -2013,7 +1759,10 @@ Default config: ```lua { "cds" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/cds_lsp.lua:4](../lua/lspconfig/configs/cds_lsp.lua#L4) +- `root_markers` : + ```lua + { "package.json", "db", "srv" } + ``` - `settings` : ```lua { @@ -2022,7 +1771,6 @@ Default config: } } ``` -- `single_file_support` : `true` --- @@ -2030,7 +1778,7 @@ Default config: [Circom Language Server](https://github.com/rubydusa/circom-lsp) -`circom-lsp`, the language server for the Circom language. + `circom-lsp`, the language server for the Circom language. Snippet to enable the language server: ```lua @@ -2046,8 +1794,10 @@ Default config: ```lua { "circom" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/circom-lsp.lua:2](../lua/lspconfig/configs/circom-lsp.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -2069,10 +1819,6 @@ Snippet to enable the language server: require'lspconfig'.clangd.setup{} ``` -Commands: -- ClangdShowSymbolInfo: Show symbol info -- ClangdSwitchSourceHeader: Switch between source/header - Default config: - `capabilities` : ```lua @@ -2093,8 +1839,11 @@ Default config: ```lua { "c", "cpp", "objc", "objcpp", "cuda", "proto" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/clangd.lua:51](../lua/lspconfig/configs/clangd.lua#L51) -- `single_file_support` : `true` +- `on_attach` source (use "gF" to open): [../lsp/clangd.lua:62](../lsp/clangd.lua#L62) +- `root_markers` : + ```lua + { ".clangd", ".clang-tidy", ".clang-format", "compile_commands.json", "compile_flags.txt", "configure.ac", ".git" } + ``` --- @@ -2102,7 +1851,7 @@ Default config: `clarity-lsp` is a language server for the Clarity language. Clarity is a decidable smart contract language that optimizes for predictability and security. Smart contracts allow developers to encode essential business logic on a blockchain. -To learn how to configure the clarity language server, see the [clarity-lsp documentation](https://github.com/hirosystems/clarity-lsp). + To learn how to configure the clarity language server, see the [clarity-lsp documentation](https://github.com/hirosystems/clarity-lsp). Snippet to enable the language server: ```lua @@ -2118,7 +1867,10 @@ Default config: ```lua { "clar", "clarity" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/clarity_lsp.lua:4](../lua/lspconfig/configs/clarity_lsp.lua#L4) +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -2142,8 +1894,10 @@ Default config: ```lua { "clojure", "edn" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/clojure_lsp.lua:4](../lua/lspconfig/configs/clojure_lsp.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "project.clj", "deps.edn", "build.boot", "shadow-cljs.edn", ".git", "bb.edn" } + ``` --- @@ -2173,8 +1927,10 @@ Default config: buildDirectory = "build" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/cmake.lua:4](../lua/lspconfig/configs/cmake.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "CMakePresets.json", "CTestConfig.cmake", ".git", "build", "cmake" } + ``` --- @@ -2196,43 +1952,9 @@ Default config: ```lua { "cobol" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/cobol_ls.lua:2](../lua/lspconfig/configs/cobol_ls.lua#L2) - ---- - -## codeqlls - -Reference: -https://codeql.github.com/docs/codeql-cli/ - -Binaries: -https://github.com/github/codeql-cli-binaries - -Snippet to enable the language server: -```lua -require'lspconfig'.codeqlls.setup{} -``` - -Default config: -- `before_init` source (use "gF" to visit): [../lua/lspconfig/configs/codeqlls.lua:6](../lua/lspconfig/configs/codeqlls.lua#L6) -- `cmd` : - ```lua - { "codeql", "execute", "language-server", "--check-errors", "ON_CHANGE", "-q" } - ``` -- `filetypes` : - ```lua - { "ql" } - ``` -- `log_level` : +- `root_markers` : ```lua - 2 - ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/codeqlls.lua:6](../lua/lspconfig/configs/codeqlls.lua#L6) -- `settings` : - ```lua - { - search_path = vim.empty_dict() - } + { ".git" } ``` --- @@ -2261,8 +1983,10 @@ Default config: ```lua { "coffee" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/coffeesense.lua:4](../lua/lspconfig/configs/coffeesense.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "package.json" } + ``` --- @@ -2288,7 +2012,10 @@ Default config: ```lua { "Contextive.LanguageServer" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/contextive.lua:4](../lua/lspconfig/configs/contextive.lua#L4) +- `root_markers` : + ```lua + { ".contextive", ".git" } + ``` --- @@ -2310,8 +2037,10 @@ Default config: ```lua { "coq" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/coq_lsp.lua:4](../lua/lspconfig/configs/coq_lsp.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "_CoqProject", ".git" } + ``` --- @@ -2335,8 +2064,10 @@ Default config: ```lua { "crystal" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/crystalline.lua:4](../lua/lspconfig/configs/crystalline.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "shard.yml", ".git" } + ``` --- @@ -2370,7 +2101,7 @@ Default config: AutomaticWorkspaceInit = true } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/csharp_ls.lua:4](../lua/lspconfig/configs/csharp_ls.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/csharp_ls.lua:12](../lsp/csharp_ls.lua#L12) --- @@ -2400,7 +2131,10 @@ Default config: ```lua { "css", "scss", "less" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/css_variables.lua:4](../lua/lspconfig/configs/css_variables.lua#L4) +- `root_markers` : + ```lua + { "package.json", ".git" } + ``` - `settings` : ```lua { @@ -2430,9 +2164,9 @@ Neovim does not currently include built-in snippets. `vscode-css-language-server local capabilities = vim.lsp.protocol.make_client_capabilities() capabilities.textDocument.completion.completionItem.snippetSupport = true -require'lspconfig'.cssls.setup { +vim.lsp.config('cssls', { capabilities = capabilities, -} +}) ``` Snippet to enable the language server: @@ -2455,7 +2189,10 @@ Default config: provideFormatter = true } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/cssls.lua:4](../lua/lspconfig/configs/cssls.lua#L4) +- `root_markers` : + ```lua + { "package.json", ".git" } + ``` - `settings` : ```lua { @@ -2470,7 +2207,6 @@ Default config: } } ``` -- `single_file_support` : `true` --- @@ -2499,7 +2235,10 @@ Default config: ```lua { "javascript", "javascriptreact", "typescript", "typescriptreact" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/cssmodules_ls.lua:2](../lua/lspconfig/configs/cssmodules_ls.lua#L2) +- `root_markers` : + ```lua + { "package.json" } + ``` --- @@ -2530,7 +2269,10 @@ Default config: ```lua { "cucumber" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/cucumber_language_server.lua:2](../lua/lspconfig/configs/cucumber_language_server.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -2554,8 +2296,10 @@ Default config: ```lua { "cue" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/cue.lua:4](../lua/lspconfig/configs/cue.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "cue.mod", ".git" } + ``` --- @@ -2601,7 +2345,7 @@ Default config: hostInfo = "neovim" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/custom_elements_ls.lua:4](../lua/lspconfig/configs/custom_elements_ls.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/custom_elements_ls.lua:26](../lsp/custom_elements_ls.lua#L26) --- @@ -2631,8 +2375,10 @@ Default config: ```lua { "cypher" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/cypher_ls.lua:2](../lua/lspconfig/configs/cypher_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -2654,7 +2400,10 @@ Default config: ```lua { "d" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/daedalus_ls.lua:14](../lua/lspconfig/configs/daedalus_ls.lua#L14) +- `root_markers` : + ```lua + { "Gothic.src", "Camera.src", "Menu.src", "Music.src", "ParticleFX.src", "SFX.src", "VisualFX.src" } + ``` - `settings` : ```lua { @@ -2676,11 +2425,6 @@ Default config: Support for the Dafny language server. - The default `cmd` uses "dafny server", which works on Dafny 4.0.0+. For - older versions of Dafny, you can compile the language server from source at - [dafny-lang/language-server-csharp](https://github.com/dafny-lang/language-server-csharp) - and set `cmd = {"dotnet", "<Path to your language server>"}`. - Snippet to enable the language server: ```lua require'lspconfig'.dafny.setup{} @@ -2695,8 +2439,10 @@ Default config: ```lua { "dfy", "dafny" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/dafny.lua:2](../lua/lspconfig/configs/dafny.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -2720,8 +2466,10 @@ Default config: ```lua { "cue" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/dagger.lua:4](../lua/lspconfig/configs/dagger.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "cue.mod", ".git" } + ``` --- @@ -2755,7 +2503,10 @@ Default config: suggestFromUnimportedLibraries = true } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/dartls.lua:4](../lua/lspconfig/configs/dartls.lua#L4) +- `root_markers` : + ```lua + { "pubspec.yaml" } + ``` - `settings` : ```lua { @@ -2788,7 +2539,10 @@ Default config: ```lua { "dart" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/dcmls.lua:4](../lua/lspconfig/configs/dcmls.lua#L4) +- `root_markers` : + ```lua + { "pubspec.yaml" } + ``` --- @@ -2812,64 +2566,10 @@ Default config: ```lua { "debcontrol", "debcopyright", "debchangelog", "make", "yaml" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/debputy.lua:4](../lua/lspconfig/configs/debputy.lua#L4) - ---- - -## delphi_ls - -Language server for Delphi from Embarcadero. -https://marketplace.visualstudio.com/items?itemName=EmbarcaderoTechnologies.delphilsp - -Note, the '*.delphilsp.json' file is required, more details at: -https://docwiki.embarcadero.com/RADStudio/Alexandria/en/Using_DelphiLSP_Code_Insight_with_Other_Editors - -Below, you'll find a sample configuration for the lazy manager. -When on_attach is triggered, it signals DelphiLSP to load settings from a configuration file. -Without this step, DelphiLSP initializes but remains non-functional: - -```lua -"neovim/nvim-lspconfig", -lazy = false, -config = function() - local capabilities = require("cmp_nvim_lsp").default_capabilities() - local lspconfig = require("lspconfig") - - lspconfig.delphi_ls.setup({ - capabilities = capabilities, - - on_attach = function(client) - local lsp_config = vim.fs.find(function(name) - return name:match(".*%.delphilsp.json$") - end, { type = "file", path = client.config.root_dir, upward = false })[1] - - if lsp_config then - client.config.settings = { settingsFile = lsp_config } - client.notify("workspace/didChangeConfiguration", { settings = client.config.settings }) - else - vim.notify_once("delphi_ls: '*.delphilsp.json' config file not found") - end - end, - }) -end, -``` - -Snippet to enable the language server: -```lua -require'lspconfig'.delphi_ls.setup{} -``` - -Default config: -- `cmd` : - ```lua - { "DelphiLSP.exe" } - ``` -- `filetypes` : +- `root_markers` : ```lua - { "pascal" } + { "debian" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/delphi_ls.lua:4](../lua/lspconfig/configs/delphi_ls.lua#L4) -- `single_file_support` : `false` --- @@ -2893,9 +2593,6 @@ Snippet to enable the language server: require'lspconfig'.denols.setup{} ``` -Commands: -- DenolsCache: Cache a module and all of its dependencies. - Default config: - `cmd` : ```lua @@ -2919,7 +2616,11 @@ Default config: ["textDocument/typeDefinition"] = <function 1> } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/denols.lua:66](../lua/lspconfig/configs/denols.lua#L66) +- `on_attach` source (use "gF" to open): [../lsp/denols.lua:78](../lsp/denols.lua#L78) +- `root_markers` : + ```lua + { "deno.json", "deno.jsonc", ".git" } + ``` - `settings` : ```lua { @@ -2964,8 +2665,10 @@ Default config: ```lua { "dhall" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/dhall_lsp_server.lua:2](../lua/lspconfig/configs/dhall_lsp_server.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -2989,8 +2692,10 @@ Default config: ```lua {} ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/diagnosticls.lua:3](../lua/lspconfig/configs/diagnosticls.lua#L3) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -3018,8 +2723,10 @@ Default config: ```lua { "tex", "plaintex", "context" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/digestif.lua:2](../lua/lspconfig/configs/digestif.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -3027,8 +2734,6 @@ Default config: https://github.com/fourdigits/django-template-lsp - `djlsp`, a language server for Django templates. - Snippet to enable the language server: ```lua require'lspconfig'.djlsp.setup{} @@ -3043,7 +2748,10 @@ Default config: ```lua { "html", "htmldjango" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/djlsp.lua:2](../lua/lspconfig/configs/djlsp.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua {} @@ -3078,8 +2786,10 @@ Default config: ```lua { "yaml.docker-compose" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/docker_compose_language_service.lua:4](../lua/lspconfig/configs/docker_compose_language_service.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "docker-compose.yaml", "docker-compose.yml", "compose.yaml", "compose.yml" } + ``` --- @@ -3094,7 +2804,7 @@ npm install -g dockerfile-language-server-nodejs Additional configuration can be applied in the following way: ```lua -require("lspconfig").dockerls.setup { +vim.lsp.config('dockerls', { settings = { docker = { languageserver = { @@ -3104,7 +2814,7 @@ require("lspconfig").dockerls.setup { }, } } -} +}) ``` Snippet to enable the language server: @@ -3121,8 +2831,10 @@ Default config: ```lua { "dockerfile" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/dockerls.lua:4](../lua/lspconfig/configs/dockerls.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "Dockerfile" } + ``` --- @@ -3149,8 +2861,10 @@ Default config: ```lua { "smt2", "tptp", "p", "cnf", "icnf", "zf" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/dolmenls.lua:2](../lua/lspconfig/configs/dolmenls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -3177,8 +2891,10 @@ Default config: ```lua { "dot" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/dotls.lua:2](../lua/lspconfig/configs/dotls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -3202,62 +2918,14 @@ Default config: ```lua { "javascript", "javascriptreact", "typescript", "typescriptreact", "json", "jsonc", "markdown", "python", "toml", "rust", "roslyn", "graphql" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/dprint.lua:4](../lua/lspconfig/configs/dprint.lua#L4) -- `settings` : +- `root_markers` : ```lua - {} + { "dprint.json", ".dprint.json", "dprint.jsonc", ".dprint.jsonc" } ``` -- `single_file_support` : `true` - ---- - -## drools_lsp - -https://github.com/kiegroup/drools-lsp - -Language server for the [Drools Rule Language (DRL)](https://docs.drools.org/latest/drools-docs/docs-website/drools/language-reference/#con-drl_drl-rules). - -The `drools-lsp` server is a self-contained java jar file (`drools-lsp-server-jar-with-dependencies.jar`), and can be downloaded from [https://github.com/kiegroup/drools-lsp/releases/](https://github.com/kiegroup/drools-lsp/releases/). - -Configuration information: -```lua --- Option 1) Specify the entire command: -require('lspconfig').drools_lsp.setup { - cmd = { '/path/to/java', '-jar', '/path/to/drools-lsp-server-jar-with-dependencies.jar' }, -} - --- Option 2) Specify just the jar path (the JAVA_HOME environment variable will be respected if present): -require('lspconfig').drools_lsp.setup { - drools = { jar = '/path/to/drools-lsp-server-jar-with-dependencies.jar' }, -} - --- Option 3) Specify the java bin and/or java opts in addition to the jar path: -require('lspconfig').drools_lsp.setup { - drools = { - java = { bin = '/path/to/java', opts = { '-Xmx100m' } }, - jar = '/path/to/drools-lsp-server-jar-with-dependencies.jar', - }, -} -``` - -Neovim does not yet have automatic detection for the `drools` filetype, but it can be added with: -```lua -vim.cmd [[ autocmd BufNewFile,BufRead *.drl set filetype=drools ]] -``` - -Snippet to enable the language server: -```lua -require'lspconfig'.drools_lsp.setup{} -``` - -Default config: -- `filetypes` : +- `settings` : ```lua - { "drools" } + {} ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/drools_lsp.lua:36](../lua/lspconfig/configs/drools_lsp.lua#L36) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/drools_lsp.lua:36](../lua/lspconfig/configs/drools_lsp.lua#L36) -- `single_file_support` : `true` --- @@ -3270,11 +2938,11 @@ And make ensure the database file `dict.db3` is also downloaded. And put the pat ```lua -require('lspconfig').ds_pinyin_lsp.setup { +vim.lsp.config('ds_pinyin_lsp', { init_options = { db_path = "your_path_to_database" } -} +}) ``` @@ -3283,10 +2951,6 @@ Snippet to enable the language server: require'lspconfig'.ds_pinyin_lsp.setup{} ``` -Commands: -- DsPinyinCompletionOff: Turn off the ds-pinyin-lsp completion -- DsPinyinCompletionOn: Turn on the ds-pinyin-lsp completion - Default config: - `cmd` : ```lua @@ -3308,8 +2972,11 @@ Default config: show_symbols_only_follow_by_hanzi = false } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ds_pinyin_lsp.lua:33](../lua/lspconfig/configs/ds_pinyin_lsp.lua#L33) -- `single_file_support` : `true` +- `on_attach` source (use "gF" to open): [../lsp/ds_pinyin_lsp.lua:48](../lsp/ds_pinyin_lsp.lua#L48) +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -3345,7 +3012,10 @@ Default config: ```lua "dts_lsp" ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/dts_lsp.lua:2](../lua/lspconfig/configs/dts_lsp.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua {} @@ -3373,7 +3043,10 @@ Default config: ```lua { "earthfile" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/earthlyls.lua:4](../lua/lspconfig/configs/earthlyls.lua#L4) +- `root_markers` : + ```lua + { "Earthfile" } + ``` --- @@ -3400,51 +3073,10 @@ Default config: ```lua { "ecsact" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ecsact.lua:4](../lua/lspconfig/configs/ecsact.lua#L4) -- `single_file_support` : `true` - ---- - -## efm - -https://github.com/mattn/efm-langserver - -General purpose Language Server that can use specified error message format generated from specified command. - -Requires at minimum EFM version [v0.0.38](https://github.com/mattn/efm-langserver/releases/tag/v0.0.38) to support -launching the language server on single files. If on an older version of EFM, disable single file support: - -```lua -require('lspconfig')['efm'].setup{ - settings = ..., -- You must populate this according to the EFM readme - filetypes = ..., -- Populate this according to the note below - single_file_support = false, -- This is the important line for supporting older version of EFM -} -``` - -Note: In order for neovim's built-in language server client to send the appropriate `languageId` to EFM, **you must -specify `filetypes` in your call to `setup{}`**. Otherwise `lspconfig` will launch EFM on the `BufEnter` instead -of the `FileType` autocommand, and the `filetype` variable used to populate the `languageId` will not yet be set. - -```lua -require('lspconfig')['efm'].setup{ - settings = ..., -- You must populate this according to the EFM readme - filetypes = { 'python','cpp','lua' } -} -``` - -Snippet to enable the language server: -```lua -require'lspconfig'.efm.setup{} -``` - -Default config: -- `cmd` : +- `root_markers` : ```lua - { "efm-langserver" } + { ".git" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/efm.lua:2](../lua/lspconfig/configs/efm.lua#L2) -- `single_file_support` : `true` --- @@ -3465,13 +3097,13 @@ https://github.com/elixir-lsp/elixir-ls **By default, elixir-ls doesn't have a `cmd` set.** This is because nvim-lspconfig does not make assumptions about your path. You must add the following to your init.vim or init.lua to set `cmd` to the absolute path ($HOME and ~ are not expanded) of your unzipped elixir-ls. ```lua -require'lspconfig'.elixirls.setup{ +vim.lsp.config('elixirls', { -- Unix cmd = { "/path/to/elixir-ls/language_server.sh" }; -- Windows cmd = { "/path/to/elixir-ls/language_server.bat" }; ... -} +}) ``` 'root_dir' is chosen like this: if two or more directories containing `mix.exs` were found when searching directories upward, the second one (higher up) is chosen, with the assumption that it is the root of an umbrella app. Otherwise the directory containing the single mix.exs that was found is chosen. @@ -3486,8 +3118,7 @@ Default config: ```lua { "elixir", "eelixir", "heex", "surface" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/elixirls.lua:2](../lua/lspconfig/configs/elixirls.lua#L2) -- `single_file_support` : `true` +- `root_dir` source (use "gF" to open): [../lsp/elixirls.lua:28](../lsp/elixirls.lua#L28) --- @@ -3529,7 +3160,7 @@ Default config: skipInstallPackageConfirmation = false } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/elmls.lua:7](../lua/lspconfig/configs/elmls.lua#L7) +- `root_dir` source (use "gF" to open): [../lsp/elmls.lua:14](../lsp/elmls.lua#L14) --- @@ -3554,8 +3185,10 @@ Default config: ```lua { "erlang" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/elp.lua:4](../lua/lspconfig/configs/elp.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "rebar.config", "erlang.mk", ".git" } + ``` --- @@ -3583,7 +3216,10 @@ Default config: ```lua { "handlebars", "typescript", "javascript", "typescript.glimmer", "javascript.glimmer" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ember.lua:4](../lua/lspconfig/configs/ember.lua#L4) +- `root_markers` : + ```lua + { "ember-cli-build.js", ".git" } + ``` --- @@ -3610,8 +3246,10 @@ Default config: ```lua { "css", "eruby", "html", "htmldjango", "javascriptreact", "less", "pug", "sass", "scss", "typescriptreact", "htmlangular" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/emmet_language_server.lua:2](../lua/lspconfig/configs/emmet_language_server.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -3638,8 +3276,10 @@ Default config: ```lua { "astro", "css", "eruby", "html", "htmldjango", "javascriptreact", "less", "pug", "sass", "scss", "svelte", "typescriptreact", "vue", "htmlangular" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/emmet_ls.lua:2](../lua/lspconfig/configs/emmet_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -3669,7 +3309,10 @@ Default config: ```lua { "erg" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/erg_language_server.lua:4](../lua/lspconfig/configs/erg_language_server.lua#L4) +- `root_markers` : + ```lua + { "package.er", ".git" } + ``` --- @@ -3702,8 +3345,10 @@ Default config: ```lua { "erlang" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/erlangls.lua:4](../lua/lspconfig/configs/erlangls.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "rebar.config", "erlang.mk", ".git" } + ``` --- @@ -3730,15 +3375,15 @@ nvim Or you can modify the default `cmd` to include the full path to the Python interpreter. ```lua -require'lspconfig'.esbonio.setup { +vim.lsp.config('esbonio', { cmd = { '/path/to/virtualenv/bin/python', '-m', 'esbonio' } -} +}) ``` Esbonio supports a number of config values passed as `init_options` on startup, for example. ```lua -require'lspconfig'.esbonio.setup { +vim.lsp.config('esbonio', { init_options = { server = { logLevel = "debug" @@ -3747,7 +3392,7 @@ require'lspconfig'.esbonio.setup { confDir = "/path/to/docs", srcDir = "${confDir}/../docs-src" } -} +}) ``` A full list and explanation of the available options can be found [here](https://docs.esbon.io/en/esbonio-language-server-v0.16.4/lsp/getting-started.html?editor=neovim-lspconfig#configuration) @@ -3766,102 +3411,9 @@ Default config: ```lua { "rst" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/esbonio.lua:2](../lua/lspconfig/configs/esbonio.lua#L2) - ---- - -## eslint - -https://github.com/hrsh7th/vscode-langservers-extracted - -`vscode-eslint-language-server` is a linting engine for JavaScript / Typescript. -It can be installed via `npm`: - -```sh -npm i -g vscode-langservers-extracted -``` - -`vscode-eslint-language-server` provides an `EslintFixAll` command that can be used to format a document on save: -```lua -lspconfig.eslint.setup({ - --- ... - on_attach = function(client, bufnr) - vim.api.nvim_create_autocmd("BufWritePre", { - buffer = bufnr, - command = "EslintFixAll", - }) - end, -}) -``` - -See [vscode-eslint](https://github.com/microsoft/vscode-eslint/blob/55871979d7af184bf09af491b6ea35ebd56822cf/server/src/eslintServer.ts#L216-L229) for configuration options. - -Messages handled in lspconfig: `eslint/openDoc`, `eslint/confirmESLintExecution`, `eslint/probeFailed`, `eslint/noLibrary` - -Additional messages you can handle: `eslint/noConfig` - -Snippet to enable the language server: -```lua -require'lspconfig'.eslint.setup{} -``` - -Commands: -- EslintFixAll: Fix all eslint problems for this buffer - -Default config: -- `cmd` : - ```lua - { "vscode-eslint-language-server", "--stdio" } - ``` -- `filetypes` : - ```lua - { "javascript", "javascriptreact", "javascript.jsx", "typescript", "typescriptreact", "typescript.tsx", "vue", "svelte", "astro" } - ``` -- `handlers` : +- `root_markers` : ```lua - { - ["eslint/confirmESLintExecution"] = <function 1>, - ["eslint/noLibrary"] = <function 2>, - ["eslint/openDoc"] = <function 3>, - ["eslint/probeFailed"] = <function 4> - } - ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/eslint.lua:51](../lua/lspconfig/configs/eslint.lua#L51) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/eslint.lua:51](../lua/lspconfig/configs/eslint.lua#L51) -- `settings` : - ```lua - { - codeAction = { - disableRuleComment = { - enable = true, - location = "separateLine" - }, - showDocumentation = { - enable = true - } - }, - codeActionOnSave = { - enable = false, - mode = "all" - }, - experimental = { - useFlatConfig = false - }, - format = true, - nodePath = "", - onIgnoredFiles = "off", - problems = { - shortenToSingleLine = false - }, - quiet = false, - rulesCustomizations = {}, - run = "onType", - useESLintClass = false, - validate = "on", - workingDirectory = { - mode = "location" - } - } + { ".git" } ``` --- @@ -3886,8 +3438,10 @@ Default config: ```lua { "fsd" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/facility_language_server.lua:2](../lua/lspconfig/configs/facility_language_server.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -3911,12 +3465,14 @@ Default config: ```lua { "fennel" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/fennel_language_server.lua:2](../lua/lspconfig/configs/fennel_language_server.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua {} ``` -- `single_file_support` : `true` --- @@ -3949,12 +3505,11 @@ Default config: ```lua { "fennel" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/fennel_ls.lua:4](../lua/lspconfig/configs/fennel_ls.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/fennel_ls.lua:11](../lsp/fennel_ls.lua#L11) - `settings` : ```lua {} ``` -- `single_file_support` : `true` --- @@ -3989,8 +3544,10 @@ Default config: ```lua { "fish" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/fish_lsp.lua:2](../lua/lspconfig/configs/fish_lsp.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -4022,7 +3579,10 @@ Default config: ```lua { "javascript", "javascriptreact", "javascript.jsx" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/flow.lua:4](../lua/lspconfig/configs/flow.lua#L4) +- `root_markers` : + ```lua + { ".flowconfig" } + ``` --- @@ -4048,8 +3608,10 @@ Default config: ```lua { "flux" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/flux_lsp.lua:2](../lua/lspconfig/configs/flux_lsp.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -4076,7 +3638,7 @@ Default config: ```lua { "foam", "OpenFOAM" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/foam_ls.lua:4](../lua/lspconfig/configs/foam_ls.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/foam_ls.lua:11](../lsp/foam_ls.lua#L11) --- @@ -4108,7 +3670,10 @@ Default config: ```lua { "fortran" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/fortls.lua:4](../lua/lspconfig/configs/fortls.lua#L4) +- `root_markers` : + ```lua + { ".fortls", ".git" } + ``` - `settings` : ```lua {} @@ -4154,7 +3719,7 @@ Default config: AutomaticWorkspaceInit = true } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/fsautocomplete.lua:4](../lua/lspconfig/configs/fsautocomplete.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/fsautocomplete.lua:21](../lsp/fsautocomplete.lua#L21) - `settings` : ```lua { @@ -4216,7 +3781,7 @@ Default config: AutomaticWorkspaceInit = true } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/fsharp_language_server.lua:4](../lua/lspconfig/configs/fsharp_language_server.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/fsharp_language_server.lua:17](../lsp/fsharp_language_server.lua#L17) - `settings` : ```lua {} @@ -4244,7 +3809,10 @@ Default config: ```lua { "fstar" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/fstar.lua:2](../lua/lspconfig/configs/fstar.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -4273,8 +3841,10 @@ Default config: ```lua { "futhark", "fut" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/futhark_lsp.lua:2](../lua/lspconfig/configs/futhark_lsp.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -4290,12 +3860,15 @@ require'lspconfig'.gdscript.setup{} ``` Default config: -- `cmd` source (use "gF" to visit): [../lua/lspconfig/configs/gdscript.lua:7](../lua/lspconfig/configs/gdscript.lua#L7) +- `cmd` source (use "gF" to open): [../lsp/gdscript.lua:9](../lsp/gdscript.lua#L9) - `filetypes` : ```lua { "gd", "gdscript", "gdscript3" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/gdscript.lua:7](../lua/lspconfig/configs/gdscript.lua#L7) +- `root_markers` : + ```lua + { "project.godot", ".git" } + ``` --- @@ -4319,53 +3892,10 @@ Default config: ```lua { "gdshader", "gdshaderinc" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/gdshader_lsp.lua:4](../lua/lspconfig/configs/gdshader_lsp.lua#L4) - ---- - -## gh_actions_ls - -https://github.com/lttb/gh-actions-language-server - -Language server for GitHub Actions. - -The projects [forgejo](https://forgejo.org/) and [gitea](https://about.gitea.com/) -design their actions to be as compatible to github as possible -with only [a few differences](https://docs.gitea.com/usage/actions/comparison#unsupported-workflows-syntax) between the systems. -The `gh_actions_ls` is therefore enabled for those `yaml` files as well. - -The `gh-actions-language-server` can be installed via `npm`: - -```sh -npm install -g gh-actions-language-server -``` - -Snippet to enable the language server: -```lua -require'lspconfig'.gh_actions_ls.setup{} -``` - -Default config: -- `capabilities` : +- `root_markers` : ```lua - { - workspace = { - didChangeWorkspaceFolders = { - dynamicRegistration = true - } - } - } + { "project.godot" } ``` -- `cmd` : - ```lua - { "gh-actions-language-server", "--stdio" } - ``` -- `filetypes` : - ```lua - { "yaml" } - ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/gh_actions_ls.lua:2](../lua/lspconfig/configs/gh_actions_ls.lua#L2) -- `single_file_support` : `false` --- @@ -4390,7 +3920,10 @@ Default config: ```lua { "haskell", "lhaskell" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ghcide.lua:4](../lua/lspconfig/configs/ghcide.lua#L4) +- `root_markers` : + ```lua + { "stack.yaml", "hie-bios", "BUILD.bazel", "cabal.config", "package.yaml" } + ``` --- @@ -4417,20 +3950,22 @@ Default config: ```lua { "vhdl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ghdl_ls.lua:4](../lua/lspconfig/configs/ghdl_ls.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "hdl-prj.json", ".git" } + ``` --- ## ginko_ls `ginko_ls` is meant to be a feature-complete language server for device-trees. -Language servers can be used in many editors, such as Visual Studio Code, Emacs -or Vim + Language servers can be used in many editors, such as Visual Studio Code, Emacs + or Vim -Install `ginko_ls` from https://github.com/Schottkyc137/ginko and add it to path + Install `ginko_ls` from https://github.com/Schottkyc137/ginko and add it to path -`ginko_ls` doesn't require any configuration. + `ginko_ls` doesn't require any configuration. Snippet to enable the language server: ```lua @@ -4446,7 +3981,10 @@ Default config: ```lua { "dts" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ginko_ls.lua:2](../lua/lspconfig/configs/ginko_ls.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua {} @@ -4480,11 +4018,11 @@ Default config: - `init_options` : ```lua { - cache_path = "/home/user/.cache/gitlab-ci-ls/", - log_path = "/home/user/.cache/gitlab-ci-ls//log/gitlab-ci-ls.log" + cache_path = ".//.cache/gitlab-ci-ls/", + log_path = ".//.cache/gitlab-ci-ls//log/gitlab-ci-ls.log" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/gitlab_ci_ls.lua:5](../lua/lspconfig/configs/gitlab_ci_ls.lua#L5) +- `root_dir` source (use "gF" to open): [../lsp/gitlab_ci_ls.lua:13](../lsp/gitlab_ci_ls.lua#L13) --- @@ -4525,12 +4063,14 @@ Default config: ```lua { "wgsl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/glasgow.lua:2](../lua/lspconfig/configs/glasgow.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua {} ``` -- `single_file_support` : `true` --- @@ -4556,50 +4096,10 @@ Default config: ```lua { "gleam" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/gleam.lua:4](../lua/lspconfig/configs/gleam.lua#L4) - ---- - -## glint - -https://github.com/typed-ember/glint - - https://typed-ember.gitbook.io/glint/ - - `glint-language-server` is installed when adding `@glint/core` to your project's devDependencies: - - ```sh - npm install @glint/core --save-dev - ``` - - or - - ```sh - yarn add -D @glint/core - ``` - - or - - ```sh - pnpm add -D @glint/core - ``` - -Snippet to enable the language server: -```lua -require'lspconfig'.glint.setup{} -``` - -Default config: -- `cmd` : - ```lua - { "glint-language-server" } - ``` -- `filetypes` : +- `root_markers` : ```lua - { "html.handlebars", "handlebars", "typescript", "typescript.glimmer", "javascript", "javascript.glimmer" } + { "gleam.toml", ".git" } ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/glint.lua:4](../lua/lspconfig/configs/glint.lua#L4) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/glint.lua:4](../lua/lspconfig/configs/glint.lua#L4) --- @@ -4627,8 +4127,10 @@ Default config: ```lua { "glsl", "vert", "tesc", "tese", "frag", "geom", "comp" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/glsl_analyzer.lua:2](../lua/lspconfig/configs/glsl_analyzer.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -4666,8 +4168,10 @@ Default config: ```lua { "glsl", "vert", "tesc", "tese", "frag", "geom", "comp" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/glslls.lua:2](../lua/lspconfig/configs/glslls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -4675,16 +4179,16 @@ Default config: Combination of both lint server and client -https://github.com/nametake/golangci-lint-langserver -https://github.com/golangci/golangci-lint + https://github.com/nametake/golangci-lint-langserver + https://github.com/golangci/golangci-lint -Installation of binaries needed is done via + Installation of binaries needed is done via -``` -go install github.com/nametake/golangci-lint-langserver@latest -go install github.com/golangci/golangci-lint/cmd/golangci-lint@latest -``` + ``` + go install github.com/nametake/golangci-lint-langserver@latest + go install github.com/golangci/golangci-lint/cmd/golangci-lint@latest + ``` Snippet to enable the language server: ```lua @@ -4706,7 +4210,10 @@ Default config: command = { "golangci-lint", "run", "--output.json.path=stdout", "--show-stats=false" } } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/golangci_lint_ls.lua:4](../lua/lspconfig/configs/golangci_lint_ls.lua#L4) +- `root_markers` : + ```lua + { ".golangci.yml", ".golangci.yaml", ".golangci.toml", ".golangci.json", "go.work", "go.mod", ".git" } + ``` --- @@ -4730,8 +4237,7 @@ Default config: ```lua { "go", "gomod", "gowork", "gotmpl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/gopls.lua:6](../lua/lspconfig/configs/gopls.lua#L6) -- `single_file_support` : `true` +- `root_dir` source (use "gF" to open): [../lsp/gopls.lua:20](../lsp/gopls.lua#L20) --- @@ -4765,7 +4271,10 @@ Default config: } } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/gradle_ls.lua:9](../lua/lspconfig/configs/gradle_ls.lua#L9) +- `root_markers` : + ```lua + { "settings.gradle", "build.gradle" } + ``` --- @@ -4807,8 +4316,10 @@ Default config: clientId = "client_BaDkMgx4X19X9UxxYRCXZo" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/grammarly.lua:2](../lua/lspconfig/configs/grammarly.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -4838,7 +4349,7 @@ Default config: ```lua { "graphql", "typescriptreact", "javascriptreact" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/graphql.lua:4](../lua/lspconfig/configs/graphql.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/graphql.lua:14](../lsp/graphql.lua#L14) --- @@ -4855,11 +4366,11 @@ Requirements: If you have installed groovy language server, you can set the `cmd` custom path as follow: ```lua -require'lspconfig'.groovyls.setup{ +vim.lsp.config('groovyls', { -- Unix cmd = { "java", "-jar", "path/to/groovyls/groovy-language-server-all.jar" }, ... -} +}) ``` Snippet to enable the language server: @@ -4876,7 +4387,10 @@ Default config: ```lua { "groovy" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/groovyls.lua:4](../lua/lspconfig/configs/groovyls.lua#L4) +- `root_markers` : + ```lua + { "Jenkinsfile", ".git" } + ``` --- @@ -4907,8 +4421,10 @@ Default config: ```lua { "scheme.guile" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/guile_ls.lua:3](../lua/lspconfig/configs/guile_ls.lua#L3) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "guix.scm", ".git" } + ``` --- @@ -4922,13 +4438,13 @@ See our [documentation](https://writewithharper.com/docs/integrations/neovim) fo In short, they should look something like this: ```lua -lspconfig.harper_ls.setup { +vim.lsp.config('harper_ls', { settings = { ["harper-ls"] = { userDictPath = "~/dict.txt" } }, -} +}) ``` Snippet to enable the language server: @@ -4945,74 +4461,9 @@ Default config: ```lua { "c", "cpp", "cs", "gitcommit", "go", "html", "java", "javascript", "lua", "markdown", "nix", "python", "ruby", "rust", "swift", "toml", "typescript", "typescriptreact", "haskell", "cmake", "typst", "php", "dart" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/harper_ls.lua:2](../lua/lspconfig/configs/harper_ls.lua#L2) -- `single_file_support` : `true` - ---- - -## haxe_language_server - -https://github.com/vshaxe/haxe-language-server - -The Haxe language server can be built by running the following commands from -the project's root directory: - - npm install - npx lix run vshaxe-build -t language-server - -This will create `bin/server.js`. Note that the server requires Haxe 3.4.0 or -higher. - -After building the language server, set the `cmd` setting in your setup -function: - -```lua -lspconfig.haxe_language_server.setup({ - cmd = {"node", "path/to/bin/server.js"}, -}) -``` - -By default, the language server is configured with the HXML compiler arguments -contained in the first `.hxml` file found in your project's root directory. -If you want to specify which one to use, set the `init_options.displayArguments` -setting: - -```lua -lspconfig.haxe_language_server.setup({ - -- ... - init_options = { - displayArguments = { "build.hxml" }, - }, -}) -``` - -Snippet to enable the language server: -```lua -require'lspconfig'.haxe_language_server.setup{} -``` - -Default config: -- `cmd` : - ```lua - { "haxe-language-server" } - ``` -- `filetypes` : - ```lua - { "haxe" } - ``` -- `init_options` : +- `root_markers` : ```lua - {} - ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/haxe_language_server.lua:10](../lua/lspconfig/configs/haxe_language_server.lua#L10) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/haxe_language_server.lua:10](../lua/lspconfig/configs/haxe_language_server.lua#L10) -- `settings` : - ```lua - { - haxe = { - executable = "haxe" - } - } + { ".git" } ``` --- @@ -5037,8 +4488,10 @@ Default config: ```lua { "vhdl", "verilog", "systemverilog" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/hdl_checker.lua:2](../lua/lspconfig/configs/hdl_checker.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -5078,18 +4531,20 @@ Default config: ```lua { "helm" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/helm_ls.lua:4](../lua/lspconfig/configs/helm_ls.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "Chart.yaml" } + ``` --- ## hhvm Language server for programs written in Hack -https://hhvm.com/ -https://github.com/facebook/hhvm -See below for how to setup HHVM & typechecker: -https://docs.hhvm.com/hhvm/getting-started/getting-started + https://hhvm.com/ + https://github.com/facebook/hhvm + See below for how to setup HHVM & typechecker: + https://docs.hhvm.com/hhvm/getting-started/getting-started Snippet to enable the language server: ```lua @@ -5105,7 +4560,10 @@ Default config: ```lua { "php", "hack" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/hhvm.lua:4](../lua/lspconfig/configs/hhvm.lua#L4) +- `root_markers` : + ```lua + { ".hhconfig" } + ``` --- @@ -5142,7 +4600,10 @@ Default config: ```lua { "haskell" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/hie.lua:4](../lua/lspconfig/configs/hie.lua#L4) +- `root_markers` : + ```lua + { "stack.yaml", "package.yaml", ".git" } + ``` --- @@ -5150,7 +4611,7 @@ Default config: `hlasm_language_server` is a language server for the High Level Assembler language used on IBM SystemZ mainframes. - To learn how to configure the HLASM language server, see the [HLASM Language Support documentation](https://github.com/eclipse-che4z/che-che4z-lsp-for-hlasm). + To learn how to configure the HLASM language server, see the [HLASM Language Support documentation](https://github.com/eclipse-che4z/che-che4z-lsp-for-hlasm). Snippet to enable the language server: ```lua @@ -5166,8 +4627,10 @@ Default config: ```lua { "hlasm" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/hlasm.lua:4](../lua/lspconfig/configs/hlasm.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".hlasmplugin" } + ``` --- @@ -5180,9 +4643,9 @@ Haskell Language Server If you are using HLS 1.9.0.0, enable the language server to launch on Cabal files as well: ```lua -require('lspconfig')['hls'].setup{ +vim.lsp.config('hls', { filetypes = { 'haskell', 'lhaskell', 'cabal' }, -} +}) ``` Snippet to enable the language server: @@ -5199,7 +4662,7 @@ Default config: ```lua { "haskell", "lhaskell" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/hls.lua:4](../lua/lspconfig/configs/hls.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/hls.lua:16](../lsp/hls.lua#L16) - `settings` : ```lua { @@ -5209,7 +4672,6 @@ Default config: } } ``` -- `single_file_support` : `true` --- @@ -5238,8 +4700,10 @@ Default config: ```lua { "hoon" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/hoon_ls.lua:2](../lua/lspconfig/configs/hoon_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -5262,9 +4726,9 @@ The code-formatting feature of the lsp can be controlled with the `provideFormat local capabilities = vim.lsp.protocol.make_client_capabilities() capabilities.textDocument.completion.completionItem.snippetSupport = true -require'lspconfig'.html.setup { +vim.lsp.config('html', { capabilities = capabilities, -} +}) ``` Snippet to enable the language server: @@ -5292,12 +4756,14 @@ Default config: provideFormatter = true } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/html.lua:4](../lua/lspconfig/configs/html.lua#L4) +- `root_markers` : + ```lua + { "package.json", ".git" } + ``` - `settings` : ```lua {} ``` -- `single_file_support` : `true` --- @@ -5326,8 +4792,10 @@ Default config: ```lua { "aspnetcorerazor", "astro", "astro-markdown", "blade", "clojure", "django-html", "htmldjango", "edge", "eelixir", "elixir", "ejs", "erb", "eruby", "gohtml", "gohtmltmpl", "haml", "handlebars", "hbs", "html", "htmlangular", "html-eex", "heex", "jade", "leaf", "liquid", "markdown", "mdx", "mustache", "njk", "nunjucks", "php", "razor", "slim", "twig", "javascript", "javascriptreact", "reason", "rescript", "typescript", "typescriptreact", "vue", "svelte", "templ" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/htmx.lua:2](../lua/lspconfig/configs/htmx.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -5351,8 +4819,10 @@ Default config: ```lua { "yaml" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/hydra_lsp.lua:4](../lua/lspconfig/configs/hydra_lsp.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -5379,8 +4849,10 @@ Default config: ```lua { "hyprlang" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/hyprls.lua:2](../lua/lspconfig/configs/hyprls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -5429,7 +4901,7 @@ Default config: ```lua { "idris2" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/idris2_lsp.lua:4](../lua/lspconfig/configs/idris2_lsp.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/idris2_lsp.lua:33](../lsp/idris2_lsp.lua#L33) --- @@ -5474,7 +4946,7 @@ Default config: ```lua { "php" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/intelephense.lua:4](../lua/lspconfig/configs/intelephense.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/intelephense.lua:29](../lsp/intelephense.lua#L29) --- @@ -5498,8 +4970,10 @@ Default config: ```lua { "janet" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/janet_lsp.lua:4](../lua/lspconfig/configs/janet_lsp.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "project.janet", ".git" } + ``` --- @@ -5521,7 +4995,10 @@ Default config: ```lua { "java" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/java_language_server.lua:4](../lua/lspconfig/configs/java_language_server.lua#L4) +- `root_markers` : + ```lua + { "build.gradle", "build.gradle.kts", "pom.xml", ".git" } + ``` - `settings` : ```lua {} @@ -5545,7 +5022,7 @@ and ensure that the `PATH` variable contains the `bin` directory of the extracte ```lua -- init.lua - require'lspconfig'.jdtls.setup{} + vim.lsp.enable('jdtls') ``` You can also pass extra custom jvm arguments with the JDTLS_JVM_ARGS environment variable as a space separated list of arguments, @@ -5560,7 +5037,7 @@ For automatic installation you can use the following unofficial installers/launc - [jdtls-launcher](https://github.com/eruizc-dev/jdtls-launcher) (Includes lombok support by default) ```lua -- init.lua - require'lspconfig'.jdtls.setup{ cmd = { 'jdtls' } } + vim.lsp.config('jdtls', { cmd = { 'jdtls' } }) ``` Snippet to enable the language server: @@ -5571,7 +5048,7 @@ require'lspconfig'.jdtls.setup{} Default config: - `cmd` : ```lua - { "jdtls", "-configuration", "/home/user/.cache/jdtls/config", "-data", "/home/user/.cache/jdtls/workspace" } + { "jdtls", "-configuration", ".//.cache/jdtls/config", "-data", ".//.cache/jdtls/workspace" } ``` - `filetypes` : ```lua @@ -5590,11 +5067,13 @@ Default config: ```lua { jvm_args = {}, - workspace = "/home/user/.cache/jdtls/workspace" + workspace = ".//.cache/jdtls/workspace" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/jdtls.lua:80](../lua/lspconfig/configs/jdtls.lua#L80) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git", "build.gradle", "build.gradle.kts", "build.xml", "pom.xml", "settings.gradle", "settings.gradle.kts" } + ``` --- @@ -5618,8 +5097,10 @@ Default config: ```lua { "python" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/jedi_language_server.lua:13](../lua/lspconfig/configs/jedi_language_server.lua#L13) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "pyproject.toml", "setup.py", "setup.cfg", "requirements.txt", "Pipfile", ".git" } + ``` --- @@ -5657,8 +5138,10 @@ Default config: ```lua "jinja_lsp" ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/jinja_lsp.lua:2](../lua/lspconfig/configs/jinja_lsp.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -5693,8 +5176,10 @@ Default config: ```lua { "jq" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/jqls.lua:2](../lua/lspconfig/configs/jqls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -5716,9 +5201,9 @@ npm i -g vscode-langservers-extracted local capabilities = vim.lsp.protocol.make_client_capabilities() capabilities.textDocument.completion.completionItem.snippetSupport = true -require'lspconfig'.jsonls.setup { +vim.lsp.config('jsonls', { capabilities = capabilities, -} +}) ``` Snippet to enable the language server: @@ -5741,39 +5226,10 @@ Default config: provideFormatter = true } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/jsonls.lua:2](../lua/lspconfig/configs/jsonls.lua#L2) -- `single_file_support` : `true` - ---- - -## jsonnet_ls - -https://github.com/grafana/jsonnet-language-server - -A Language Server Protocol (LSP) server for Jsonnet. - -The language server can be installed with `go`: -```sh -go install github.com/grafana/jsonnet-language-server@latest -``` - -Snippet to enable the language server: -```lua -require'lspconfig'.jsonnet_ls.setup{} -``` - -Default config: -- `cmd` : - ```lua - { "jsonnet-language-server" } - ``` -- `filetypes` : +- `root_markers` : ```lua - { "jsonnet", "libsonnet" } + { ".git" } ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/jsonnet_ls.lua:13](../lua/lspconfig/configs/jsonnet_ls.lua#L13) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/jsonnet_ls.lua:13](../lua/lspconfig/configs/jsonnet_ls.lua#L13) -- `single_file_support` : `true` --- @@ -5807,9 +5263,6 @@ Snippet to enable the language server: require'lspconfig'.julials.setup{} ``` -Commands: -- JuliaActivateEnv: Activate a Julia environment - Default config: - `cmd` : ```lua @@ -5819,8 +5272,11 @@ Default config: ```lua { "julia" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/julials.lua:97](../lua/lspconfig/configs/julials.lua#L97) -- `single_file_support` : `true` +- `on_attach` source (use "gF" to open): [../lsp/julials.lua:118](../lsp/julials.lua#L118) +- `root_markers` : + ```lua + { "Project.toml", "JuliaProject.toml" } + ``` --- @@ -5844,8 +5300,10 @@ Default config: ```lua { "just" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/just.lua:2](../lua/lspconfig/configs/just.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -5869,7 +5327,10 @@ Default config: ```lua { "kcl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/kcl.lua:4](../lua/lspconfig/configs/kcl.lua#L4) +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -5892,28 +5353,18 @@ Default config: ```lua { "koka" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/koka.lua:2](../lua/lspconfig/configs/koka.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- ## kotlin_language_server A kotlin language server which was developed for internal usage and - released afterwards. Maintaining is not done by the original author, - but by fwcd. - - It is built via gradle and developed on github. - Source and additional description: - https://github.com/fwcd/kotlin-language-server - - This server requires vim to be aware of the kotlin-filetype. - You could refer for this capability to: - https://github.com/udalov/kotlin-vim (recommended) - Note that there is no LICENSE specified yet. - - For faster startup, you can setup caching by specifying a storagePath - in the init_options. The default is your home directory. + released afterwards. Maintaining is not done by the original author, + but by fwcd. Snippet to enable the language server: ```lua @@ -5933,7 +5384,10 @@ Default config: ```lua {} ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/kotlin_language_server.lua:20](../lua/lspconfig/configs/kotlin_language_server.lua#L20) +- `root_markers` : + ```lua + { "settings.gradle", "settings.gradle.kts", "build.xml", "pom.xml", "build.gradle", "build.gradle.kts" } + ``` --- @@ -5957,8 +5411,10 @@ Default config: ```lua { "http" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/kulala_ls.lua:2](../lua/lspconfig/configs/kulala_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -5996,42 +5452,7 @@ Default config: ```lua "utf-32" ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/lean3ls.lua:4](../lua/lspconfig/configs/lean3ls.lua#L4) -- `single_file_support` : `true` - ---- - -## leanls - -https://github.com/leanprover/lean4 - -Lean installation instructions can be found -[here](https://leanprover-community.github.io/get_started.html#regular-install). - -The Lean language server is included in any Lean installation and -does not require any additional packages. - -Note: that if you're using [lean.nvim](https://github.com/Julian/lean.nvim), -that plugin fully handles the setup of the Lean language server, -and you shouldn't set up `leanls` both with it and `lspconfig`. - -Snippet to enable the language server: -```lua -require'lspconfig'.leanls.setup{} -``` - -Default config: -- `cmd` : - ```lua - { "lake", "serve", "--" } - ``` -- `filetypes` : - ```lua - { "lean" } - ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/leanls.lua:4](../lua/lspconfig/configs/leanls.lua#L4) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/leanls.lua:4](../lua/lspconfig/configs/leanls.lua#L4) -- `single_file_support` : `true` +- `root_dir` source (use "gF" to open): [../lsp/lean3ls.lua:18](../lsp/lean3ls.lua#L18) --- @@ -6060,7 +5481,10 @@ Default config: ```lua { "llw" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/lelwel_ls.lua:2](../lua/lspconfig/configs/lelwel_ls.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -6086,8 +5510,10 @@ Default config: ```lua { "xml", "xsd", "xsl", "xslt", "svg" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/lemminx.lua:2](../lua/lspconfig/configs/lemminx.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -6112,8 +5538,10 @@ Default config: ```lua { "elixir", "eelixir", "heex", "surface" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/lexical.lua:4](../lua/lspconfig/configs/lexical.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "mix.exs", ".git" } + ``` --- @@ -6152,7 +5580,6 @@ Default config: models = vim.empty_dict() } ``` -- `single_file_support` : `true` --- @@ -6194,8 +5621,11 @@ Default config: ```lua { "bib", "gitcommit", "markdown", "org", "plaintex", "rst", "rnoweb", "tex", "pandoc", "quarto", "rmd", "context", "html", "xhtml", "mail", "text" } ``` -- `get_language_id` source (use "gF" to visit): [../lua/lspconfig/configs/ltex.lua:51](../lua/lspconfig/configs/ltex.lua#L51) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ltex.lua:51](../lua/lspconfig/configs/ltex.lua#L51) +- `get_language_id` source (use "gF" to open): [../lsp/ltex.lua:73](../lsp/ltex.lua#L73) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua { @@ -6204,7 +5634,6 @@ Default config: } } ``` -- `single_file_support` : `true` --- @@ -6246,8 +5675,11 @@ Default config: ```lua { "bib", "context", "gitcommit", "html", "markdown", "org", "pandoc", "plaintex", "quarto", "mail", "mdx", "rmd", "rnoweb", "rst", "tex", "text", "typst", "xhtml" } ``` -- `get_language_id` source (use "gF" to visit): [../lua/lspconfig/configs/ltex_plus.lua:16](../lua/lspconfig/configs/ltex_plus.lua#L16) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ltex_plus.lua:16](../lua/lspconfig/configs/ltex_plus.lua#L16) +- `get_language_id` source (use "gF" to open): [../lsp/ltex_plus.lua:38](../lsp/ltex_plus.lua#L38) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua { @@ -6256,7 +5688,6 @@ Default config: } } ``` -- `single_file_support` : `true` --- @@ -6275,7 +5706,7 @@ analysis, and location handling for plugins on runtime path, you can use the fol settings. ```lua -require'lspconfig'.lua_ls.setup { +vim.lsp.config('lua_ls', { on_init = function(client) if client.workspace_folders then local path = client.workspace_folders[1].name @@ -6307,7 +5738,7 @@ require'lspconfig'.lua_ls.setup { settings = { Lua = {} } -} +}) ``` See `lua-language-server`'s [documentation](https://luals.github.io/wiki/settings/) for an explanation of the above fields: @@ -6328,18 +5759,26 @@ Default config: ```lua { "lua" } ``` -- `log_level` : +- `root_markers` : ```lua - 2 + { ".luarc.json", ".luarc.jsonc", ".luacheckrc", ".stylua.toml", "stylua.toml", "selene.toml", "selene.yml", ".git" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/lua_ls.lua:15](../lua/lspconfig/configs/lua_ls.lua#L15) -- `single_file_support` : `true` --- ## luau_lsp +https://github.com/JohnnyMorganz/luau-lsp + +Language server for the [Luau](https://luau-lang.org/) language. +`luau-lsp` can be installed by downloading one of the release assets available at https://github.com/JohnnyMorganz/luau-lsp. + +You might also have to set up automatic filetype detection for Luau files, for example like so: + +```vim +autocmd BufRead,BufNewFile *.luau setf luau +``` Snippet to enable the language server: ```lua @@ -6355,8 +5794,10 @@ Default config: ```lua { "luau" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/luau_lsp.lua:2](../lua/lspconfig/configs/luau_lsp.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -6370,13 +5811,13 @@ For manual installation, utilize the official [NPM package](https://www.npmjs.co Then, configure `cmd` to run the Node script at the unpacked location: ```lua -require'lspconfig'.lwc_ls.setup { +vim.lsp.config('lwc_ls', { cmd = { 'node', '/path/to/node_modules/@salesforce/lwc-language-server/bin/lwc-language-server.js', '--stdio' } -} +}) ``` Snippet to enable the language server: @@ -6401,7 +5842,10 @@ Default config: } } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/lwc_ls.lua:4](../lua/lspconfig/configs/lwc_ls.lua#L4) +- `root_markers` : + ```lua + { "sfdx-project.json" } + ``` --- @@ -6437,8 +5881,10 @@ Default config: ```lua { "asm68k" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/m68k.lua:4](../lua/lspconfig/configs/m68k.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "Makefile", ".git" } + ``` --- @@ -6458,11 +5904,6 @@ Snippet to enable the language server: require'lspconfig'.markdown_oxide.setup{} ``` -Commands: -- Today: Open today's daily note -- Tomorrow: Open tomorrow's daily note -- Yesterday: Open yesterday's daily note - Default config: - `cmd` : ```lua @@ -6472,8 +5913,11 @@ Default config: ```lua { "markdown" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/markdown_oxide.lua:2](../lua/lspconfig/configs/markdown_oxide.lua#L2) -- `single_file_support` : `true` +- `on_attach` source (use "gF" to open): [../lsp/markdown_oxide.lua:11](../lsp/markdown_oxide.lua#L11) +- `root_markers` : + ```lua + { ".git", ".obsidian", ".moxide.toml" } + ``` --- @@ -6481,13 +5925,6 @@ Default config: https://github.com/marko-js/language-server - Using the Language Server Protocol to improve Marko's developer experience. - - Can be installed via npm: - ``` - npm i -g @marko/language-server - ``` - Snippet to enable the language server: ```lua require'lspconfig'.marko-js.setup{} @@ -6502,7 +5939,10 @@ Default config: ```lua { "marko" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/marko-js.lua:2](../lua/lspconfig/configs/marko-js.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -6530,80 +5970,10 @@ Default config: ```lua { "markdown", "markdown.mdx" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/marksman.lua:7](../lua/lspconfig/configs/marksman.lua#L7) -- `single_file_support` : `true` - ---- - -## matlab_ls - -https://github.com/mathworks/MATLAB-language-server - -MATLAB® language server implements the Microsoft® Language Server Protocol for the MATLAB language. - -Snippet to enable the language server: -```lua -require'lspconfig'.matlab_ls.setup{} -``` - -Default config: -- `cmd` : - ```lua - { "matlab-language-server", "--stdio" } - ``` -- `filetypes` : - ```lua - { "matlab" } - ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/matlab_ls.lua:2](../lua/lspconfig/configs/matlab_ls.lua#L2) -- `settings` : - ```lua - { - MATLAB = { - indexWorkspace = false, - installPath = "", - matlabConnectionTiming = "onStart", - telemetry = true - } - } - ``` -- `single_file_support` : `false` - ---- - -## mdx_analyzer - -https://github.com/mdx-js/mdx-analyzer - -`mdx-analyzer`, a language server for MDX - -Snippet to enable the language server: -```lua -require'lspconfig'.mdx_analyzer.setup{} -``` - -Default config: -- `cmd` : - ```lua - { "mdx-language-server", "--stdio" } - ``` -- `filetypes` : - ```lua - { "mdx" } - ``` -- `init_options` : +- `root_markers` : ```lua - { - typescript = {} - } + { ".marksman.toml", ".git" } ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/mdx_analyzer.lua:9](../lua/lspconfig/configs/mdx_analyzer.lua#L9) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/mdx_analyzer.lua:9](../lua/lspconfig/configs/mdx_analyzer.lua#L9) -- `settings` : - ```lua - {} - ``` -- `single_file_support` : `true` --- @@ -6627,7 +5997,10 @@ Default config: ```lua { "meson" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/mesonlsp.lua:4](../lua/lspconfig/configs/mesonlsp.lua#L4) +- `root_markers` : + ```lua + { "meson.build", "meson_options.txt", "meson.options", ".git" } + ``` --- @@ -6677,11 +6050,10 @@ Default config: statusBarProvider = "show-message" } ``` -- `message_level` : +- `root_markers` : ```lua - 4 + { "build.sbt", "build.sc", "build.gradle", "pom.xml" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/metals.lua:4](../lua/lspconfig/configs/metals.lua#L4) --- @@ -6712,8 +6084,10 @@ Default config: ```lua { "sml" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/millet.lua:4](../lua/lspconfig/configs/millet.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "millet.toml" } + ``` --- @@ -6738,8 +6112,10 @@ Default config: ```lua { "mint" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/mint.lua:4](../lua/lspconfig/configs/mint.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "mint.json", ".git" } + ``` --- @@ -6765,8 +6141,10 @@ Default config: ```lua { "mlir" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/mlir_lsp_server.lua:2](../lua/lspconfig/configs/mlir_lsp_server.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -6792,7 +6170,10 @@ Default config: ```lua { "pdll" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/mlir_pdll_lsp_server.lua:4](../lua/lspconfig/configs/mlir_pdll_lsp_server.lua#L4) +- `root_markers` : + ```lua + { "pdll_compile_commands.yml", ".git" } + ``` --- @@ -6819,8 +6200,10 @@ Default config: ```lua { "metamath-zero" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/mm0_ls.lua:2](../lua/lspconfig/configs/mm0_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -6846,8 +6229,10 @@ Default config: ```lua { "mojo" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/mojo.lua:2](../lua/lspconfig/configs/mojo.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -6877,8 +6262,10 @@ Default config: formatter = "auto" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/motoko_lsp.lua:4](../lua/lspconfig/configs/motoko_lsp.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "dfx.json", ".git" } + ``` --- @@ -6910,7 +6297,10 @@ Default config: ```lua { "move" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/move_analyzer.lua:4](../lua/lspconfig/configs/move_analyzer.lua#L4) +- `root_markers` : + ```lua + { "Move.toml" } + ``` --- @@ -6922,9 +6312,9 @@ MSBuild Project Tools Server can be installed by following the README.MD on the Example config: ```lua -lspconfig.msbuild_project_tools_server.setup { +vim.lsp.config('msbuild_project_tools_server', { cmd = {'dotnet', '/path/to/server/MSBuildProjectTools.LanguageServer.Host.dll'} -} +}) ``` There's no builtin filetypes for msbuild files, would require some filetype aliases: @@ -6966,7 +6356,7 @@ Default config: ```lua {} ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/msbuild_project_tools_server.lua:5](../lua/lspconfig/configs/msbuild_project_tools_server.lua#L5) +- `root_dir` source (use "gF" to open): [../lsp/msbuild_project_tools_server.lua:37](../lsp/msbuild_project_tools_server.lua#L37) --- @@ -6988,7 +6378,7 @@ Default config: ```lua { "meson" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/muon.lua:4](../lua/lspconfig/configs/muon.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/muon.lua:4](../lsp/muon.lua#L4) --- @@ -7016,12 +6406,14 @@ Default config: ```lua { "muttrc", "neomuttrc" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/mutt_ls.lua:2](../lua/lspconfig/configs/mutt_ls.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua {} ``` -- `single_file_support` : `true` --- @@ -7046,9 +6438,9 @@ vim.api.nvim_create_autocmd({ "BufNewFile", "BufRead" }, { pattern = { "*.nelua" **By default, nelua-lsp doesn't have a `cmd` set.** This is because nvim-lspconfig does not make assumptions about your path. You must add the following to your init.vim or init.lua to set `cmd` to the absolute path ($HOME and ~ are not expanded) of the unzipped run script or binary. ```lua -require'lspconfig'.nelua_lsp.setup { +vim.lsp.config('nelua_lsp.setup, { cmd = { "nelua", "-L", "/path/to/nelua-lsp/", "--script", "/path/to/nelua-lsp/nelua-lsp.lua" }, -} +}) ``` Snippet to enable the language server: @@ -7061,8 +6453,10 @@ Default config: ```lua { "nelua" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/nelua_lsp.lua:4](../lua/lspconfig/configs/nelua_lsp.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "Makefile", ".git", "*.nelua" } + ``` --- @@ -7079,9 +6473,9 @@ Neovim does not currently include built-in snippets. `neocmakelsp` only provides local capabilities = vim.lsp.protocol.make_client_capabilities() capabilities.textDocument.completion.completionItem.snippetSupport = true -require'lspconfig'.neocmake.setup { +vim.lsp.config('neocmake', { capabilities = capabilities, -} +}) ``` Snippet to enable the language server: @@ -7098,8 +6492,10 @@ Default config: ```lua { "cmake" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/neocmake.lua:4](../lua/lspconfig/configs/neocmake.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git", "build", "cmake" } + ``` --- @@ -7115,10 +6511,9 @@ Requirements: If you have installed nextflow language server, you can set the `cmd` custom path as follow: ```lua -require'lspconfig'.nextflow_ls.setup{ +vim.lsp.config('nextflow_ls', { cmd = { 'java', '-jar', 'nextflow-language-server-all.jar' }, filetypes = { 'nextflow' }, - root_dir = util.root_pattern('nextflow.config', '.git'), settings = { nextflow = { files = { @@ -7126,7 +6521,7 @@ require'lspconfig'.nextflow_ls.setup{ }, }, }, -} +}) ``` Snippet to enable the language server: @@ -7143,7 +6538,10 @@ Default config: ```lua { "nextflow" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/nextflow_ls.lua:4](../lua/lspconfig/configs/nextflow_ls.lua#L4) +- `root_markers` : + ```lua + { "nextflow.config", ".git" } + ``` - `settings` : ```lua { @@ -7173,8 +6571,10 @@ Default config: ```lua { "elixir", "eelixir", "heex", "surface" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/nextls.lua:4](../lua/lspconfig/configs/nextls.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "mix.exs", ".git" } + ``` --- @@ -7202,8 +6602,10 @@ Default config: ```lua { "nginx" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/nginx_language_server.lua:4](../lua/lspconfig/configs/nginx_language_server.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "nginx.conf", ".git" } + ``` --- @@ -7247,7 +6649,10 @@ Default config: ```lua { "ncl", "nickel" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/nickel_ls.lua:2](../lua/lspconfig/configs/nickel_ls.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -7276,8 +6681,10 @@ Default config: ```lua { "nix" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/nil_ls.lua:4](../lua/lspconfig/configs/nil_ls.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "flake.nix", ".git" } + ``` --- @@ -7305,8 +6712,7 @@ Default config: ```lua { "nim" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/nim_langserver.lua:4](../lua/lspconfig/configs/nim_langserver.lua#L4) -- `single_file_support` : `true` +- `root_dir` source (use "gF" to open): [../lsp/nim_langserver.lua:12](../lsp/nim_langserver.lua#L12) --- @@ -7334,8 +6740,7 @@ Default config: ```lua { "nim" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/nimls.lua:4](../lua/lspconfig/configs/nimls.lua#L4) -- `single_file_support` : `true` +- `root_dir` source (use "gF" to open): [../lsp/nimls.lua:12](../lsp/nimls.lua#L12) --- @@ -7362,8 +6767,10 @@ Default config: ```lua { "nix" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/nixd.lua:4](../lua/lspconfig/configs/nixd.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "flake.nix", "git" } + ``` --- @@ -7378,7 +6785,7 @@ Add the executable to your system or vim PATH and it will be set to go. No configuration option is needed unless you choose not to add `nomad-lsp` executable to the PATH. You should know what you are doing if you choose so. ```lua -require('lspconfig').nomad_lsp.setup{ } +vim.lsp.enable('nomad_lsp') ``` However, a `hcl.nomad` or `nomad` filetype should be defined. @@ -7399,7 +6806,7 @@ Default config: ```lua { "hcl.nomad", "nomad" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/nomad_lsp.lua:9](../lua/lspconfig/configs/nomad_lsp.lua#L9) +- `root_dir` source (use "gF" to open): [../lsp/nomad_lsp.lua:25](../lsp/nomad_lsp.lua#L25) --- @@ -7409,12 +6816,12 @@ https://github.com/nokia/ntt Installation instructions can be found [here](https://github.com/nokia/ntt#Install). Can be configured by passing a "settings" object to `ntt.setup{}`: ```lua -require('lspconfig').ntt.setup{ +vim.lsp.config('ntt', { settings = { ntt = { } } -} +}) ``` Snippet to enable the language server: @@ -7431,7 +6838,10 @@ Default config: ```lua { "ttcn" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ntt.lua:5](../lua/lspconfig/configs/ntt.lua#L5) +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -7455,8 +6865,10 @@ Default config: ```lua { "nu" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/nushell.lua:2](../lua/lspconfig/configs/nushell.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -7485,7 +6897,10 @@ Default config: ```lua { "json", "jsonc" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/nxls.lua:4](../lua/lspconfig/configs/nxls.lua#L4) +- `root_markers` : + ```lua + { "nx.json", ".git" } + ``` --- @@ -7512,7 +6927,7 @@ Default config: ```lua { "ocaml", "reason" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ocamlls.lua:4](../lua/lspconfig/configs/ocamlls.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/ocamlls.lua:11](../lsp/ocamlls.lua#L11) --- @@ -7541,8 +6956,8 @@ Default config: ```lua { "ocaml", "menhir", "ocamlinterface", "ocamllex", "reason", "dune" } ``` -- `get_language_id` source (use "gF" to visit): [../lua/lspconfig/configs/ocamllsp.lua:17](../lua/lspconfig/configs/ocamllsp.lua#L17) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ocamllsp.lua:17](../lua/lspconfig/configs/ocamllsp.lua#L17) +- `get_language_id` source (use "gF" to open): [../lsp/ocamllsp.lua:26](../lsp/ocamllsp.lua#L26) +- `root_dir` source (use "gF" to open): [../lsp/ocamllsp.lua:26](../lsp/ocamllsp.lua#L26) --- @@ -7550,7 +6965,7 @@ Default config: https://github.com/DanielGavin/ols - `Odin Language Server`. +`Odin Language Server`. Snippet to enable the language server: ```lua @@ -7566,98 +6981,7 @@ Default config: ```lua { "odin" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ols.lua:4](../lua/lspconfig/configs/ols.lua#L4) - ---- - -## omnisharp - -https://github.com/omnisharp/omnisharp-roslyn -OmniSharp server based on Roslyn workspaces - -`omnisharp-roslyn` can be installed by downloading and extracting a release from [here](https://github.com/OmniSharp/omnisharp-roslyn/releases). -OmniSharp can also be built from source by following the instructions [here](https://github.com/omnisharp/omnisharp-roslyn#downloading-omnisharp). - -OmniSharp requires the [dotnet-sdk](https://dotnet.microsoft.com/download) to be installed. - -**By default, omnisharp-roslyn doesn't have a `cmd` set.** This is because nvim-lspconfig does not make assumptions about your path. You must add the following to your init.vim or init.lua to set `cmd` to the absolute path ($HOME and ~ are not expanded) of the unzipped run script or binary. - -For `go_to_definition` to work fully, extended `textDocument/definition` handler is needed, for example see [omnisharp-extended-lsp.nvim](https://github.com/Hoffs/omnisharp-extended-lsp.nvim) - -```lua -require'lspconfig'.omnisharp.setup { - cmd = { "dotnet", "/path/to/omnisharp/OmniSharp.dll" }, - - settings = { - FormattingOptions = { - -- Enables support for reading code style, naming convention and analyzer - -- settings from .editorconfig. - EnableEditorConfigSupport = true, - -- Specifies whether 'using' directives should be grouped and sorted during - -- document formatting. - OrganizeImports = nil, - }, - MsBuild = { - -- If true, MSBuild project system will only load projects for files that - -- were opened in the editor. This setting is useful for big C# codebases - -- and allows for faster initialization of code navigation features only - -- for projects that are relevant to code that is being edited. With this - -- setting enabled OmniSharp may load fewer projects and may thus display - -- incomplete reference lists for symbols. - LoadProjectsOnDemand = nil, - }, - RoslynExtensionsOptions = { - -- Enables support for roslyn analyzers, code fixes and rulesets. - EnableAnalyzersSupport = nil, - -- Enables support for showing unimported types and unimported extension - -- methods in completion lists. When committed, the appropriate using - -- directive will be added at the top of the current file. This option can - -- have a negative impact on initial completion responsiveness, - -- particularly for the first few completion sessions after opening a - -- solution. - EnableImportCompletion = nil, - -- Only run analyzers against open files when 'enableRoslynAnalyzers' is - -- true - AnalyzeOpenDocumentsOnly = nil, - }, - Sdk = { - -- Specifies whether to include preview versions of the .NET SDK when - -- determining which version to use for project loading. - IncludePrereleases = true, - }, - }, -} -``` - -Snippet to enable the language server: -```lua -require'lspconfig'.omnisharp.setup{} -``` - -Default config: -- `filetypes` : - ```lua - { "cs", "vb" } - ``` -- `init_options` : - ```lua - {} - ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/omnisharp.lua:4](../lua/lspconfig/configs/omnisharp.lua#L4) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/omnisharp.lua:4](../lua/lspconfig/configs/omnisharp.lua#L4) -- `settings` : - ```lua - { - FormattingOptions = { - EnableEditorConfigSupport = true - }, - MsBuild = {}, - RoslynExtensionsOptions = {}, - Sdk = { - IncludePrereleases = true - } - } - ``` +- `root_dir` source (use "gF" to open): [../lsp/ols.lua:8](../lsp/ols.lua#L8) --- @@ -7683,52 +7007,10 @@ Default config: ```lua { "opencl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/opencl_ls.lua:2](../lua/lspconfig/configs/opencl_ls.lua#L2) - ---- - -## openedge_ls - -[Language server](https://github.com/vscode-abl/vscode-abl) for Progress OpenEdge ABL. - -For manual installation, download abl-lsda.jar from the [VSCode extension](https://github.com/vscode-abl/vscode-abl/releases/latest). - -Configuration - -```lua -require('lspconfig').openedge_ls.setup { - oe_jar_path = '/path/to/abl-lsda.jar', - debug = false, -- Set to true for debug logging - trace = false, -- Set to true for trace logging (REALLY verbose) - init_options = { - abl = { - configuration = { - runtimes = { - { name = '12.8', path = '/opt/progress/dlc' } - }, - maxThreads = 1 - }, - completion = { - upperCase = false - }, - buildMode = 1 -- Build all - } - } -} -``` - -Snippet to enable the language server: -```lua -require'lspconfig'.openedge_ls.setup{} -``` - -Default config: -- `filetypes` : +- `root_markers` : ```lua - { "progress" } + { ".git" } ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/openedge_ls.lua:4](../lua/lspconfig/configs/openedge_ls.lua#L4) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/openedge_ls.lua:4](../lua/lspconfig/configs/openedge_ls.lua#L4) --- @@ -7767,8 +7049,10 @@ Default config: ```lua { "openscad" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/openscad_ls.lua:2](../lua/lspconfig/configs/openscad_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -7797,45 +7081,10 @@ Default config: ```lua { "openscad" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/openscad_lsp.lua:2](../lua/lspconfig/configs/openscad_lsp.lua#L2) -- `single_file_support` : `true` - ---- - -## oxlint - -https://oxc.rs - -A collection of JavaScript tools written in Rust. - -```sh -npm install [-g] oxlint -``` - -Snippet to enable the language server: -```lua -require'lspconfig'.oxlint.setup{} -``` - -Default config: -- `cmd` : - ```lua - { "oxc_language_server" } - ``` -- `commands` : - ```lua - { - OxcFixAll = { <function 1>, - description = "Apply fixes to current buffer using oxlint (--fix)" - } - } - ``` -- `filetypes` : +- `root_markers` : ```lua - { "astro", "javascript", "javascriptreact", "svelte", "typescript", "typescript.tsx", "typescriptreact", "vue" } + { ".git" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/oxlint.lua:4](../lua/lspconfig/configs/oxlint.lua#L4) -- `single_file_support` : `false` --- @@ -7859,8 +7108,10 @@ Default config: ```lua { "pact" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/pact_ls.lua:2](../lua/lspconfig/configs/pact_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -7895,8 +7146,7 @@ Default config: ```lua { "pascal" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/pasls.lua:4](../lua/lspconfig/configs/pasls.lua#L4) -- `single_file_support` : `true` +- `root_dir` source (use "gF" to open): [../lsp/pasls.lua:19](../lsp/pasls.lua#L19) --- @@ -7927,7 +7177,10 @@ Default config: ```lua { "proto" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/pbls.lua:4](../lua/lspconfig/configs/pbls.lua#L4) +- `root_markers` : + ```lua + { ".pbls.toml", ".git" } + ``` --- @@ -7953,7 +7206,10 @@ Default config: ```lua { "perl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/perlls.lua:2](../lua/lspconfig/configs/perlls.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua { @@ -7965,7 +7221,6 @@ Default config: } } ``` -- `single_file_support` : `true` --- @@ -8005,8 +7260,10 @@ Default config: ```lua { "perl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/perlnavigator.lua:2](../lua/lspconfig/configs/perlnavigator.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -8033,7 +7290,10 @@ Default config: ```lua { "perl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/perlpls.lua:2](../lua/lspconfig/configs/perlpls.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua { @@ -8047,7 +7307,6 @@ Default config: } } ``` -- `single_file_support` : `true` --- @@ -8071,8 +7330,10 @@ Default config: ```lua { "pest" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/pest_ls.lua:2](../lua/lspconfig/configs/pest_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -8096,8 +7357,7 @@ Default config: ```lua { "php" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/phan.lua:17](../lua/lspconfig/configs/phan.lua#L17) -- `single_file_support` : `true` +- `root_dir` source (use "gF" to open): [../lsp/phan.lua:21](../lsp/phan.lua#L21) --- @@ -8121,7 +7381,7 @@ Default config: ```lua { "php" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/phpactor.lua:4](../lua/lspconfig/configs/phpactor.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/phpactor.lua:8](../lsp/phpactor.lua#L8) --- @@ -8145,7 +7405,7 @@ Default config: ```lua { "p8" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/pico8_ls.lua:4](../lua/lspconfig/configs/pico8_ls.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/pico8_ls.lua:8](../lsp/pico8_ls.lua#L8) - `settings` : ```lua {} @@ -8173,7 +7433,10 @@ Default config: ```lua { "PKGBUILD" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/pkgbuild_language_server.lua:2](../lua/lspconfig/configs/pkgbuild_language_server.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -8199,8 +7462,10 @@ Default config: ```lua { "bzl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/please.lua:4](../lua/lspconfig/configs/please.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".plzconfig" } + ``` --- @@ -8224,8 +7489,10 @@ Default config: ```lua { "pory" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/poryscript_pls.lua:2](../lua/lspconfig/configs/poryscript_pls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -8249,67 +7516,10 @@ Default config: ```lua { "sql" } ``` -- `single_file_support` : `true` - ---- - -## powershell_es - -https://github.com/PowerShell/PowerShellEditorServices - -Language server for PowerShell. - -To install, download and extract PowerShellEditorServices.zip -from the [releases](https://github.com/PowerShell/PowerShellEditorServices/releases). -To configure the language server, set the property `bundle_path` to the root -of the extracted PowerShellEditorServices.zip. - -The default configuration doesn't set `cmd` unless `bundle_path` is specified. - -```lua -require'lspconfig'.powershell_es.setup{ - bundle_path = 'c:/w/PowerShellEditorServices', -} -``` - -By default the languageserver is started in `pwsh` (PowerShell Core). This can be changed by specifying `shell`. - -```lua -require'lspconfig'.powershell_es.setup{ - bundle_path = 'c:/w/PowerShellEditorServices', - shell = 'powershell.exe', -} -``` - -Note that the execution policy needs to be set to `Unrestricted` for the languageserver run under PowerShell - -If necessary, specific `cmd` can be defined instead of `bundle_path`. -See [PowerShellEditorServices](https://github.com/PowerShell/PowerShellEditorServices#stdio) -to learn more. - -```lua -require'lspconfig'.powershell_es.setup{ - cmd = {'pwsh', '-NoLogo', '-NoProfile', '-Command', "c:/PSES/Start-EditorServices.ps1 ..."} -} -``` - -Snippet to enable the language server: -```lua -require'lspconfig'.powershell_es.setup{} -``` - -Default config: -- `filetypes` : - ```lua - { "ps1" } - ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/powershell_es.lua:14](../lua/lspconfig/configs/powershell_es.lua#L14) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/powershell_es.lua:14](../lua/lspconfig/configs/powershell_es.lua#L14) -- `shell` : +- `root_markers` : ```lua - "pwsh" + { "postgrestools.jsonc" } ``` -- `single_file_support` : `true` --- @@ -8317,10 +7527,10 @@ Default config: Language Server for the Prisma JavaScript and TypeScript ORM -`@prisma/language-server` can be installed via npm -```sh -npm install -g @prisma/language-server -``` + `@prisma/language-server` can be installed via npm + ```sh + npm install -g @prisma/language-server + ``` Snippet to enable the language server: ```lua @@ -8336,7 +7546,10 @@ Default config: ```lua { "prisma" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/prismals.lua:4](../lua/lspconfig/configs/prismals.lua#L4) +- `root_markers` : + ```lua + { ".git", "package.json" } + ``` - `settings` : ```lua { @@ -8352,7 +7565,7 @@ Default config: https://github.com/jamesnvc/lsp_server - Language Server Protocol server for SWI-Prolog +Language Server Protocol server for SWI-Prolog Snippet to enable the language server: ```lua @@ -8368,8 +7581,10 @@ Default config: ```lua { "prolog" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/prolog_ls.lua:4](../lua/lspconfig/configs/prolog_ls.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "pack.pl" } + ``` --- @@ -8395,8 +7610,10 @@ Default config: ```lua { "markdown" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/prosemd_lsp.lua:2](../lua/lspconfig/configs/prosemd_lsp.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -8425,8 +7642,10 @@ Default config: ```lua { "proto" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/protols.lua:2](../lua/lspconfig/configs/protols.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -8453,7 +7672,10 @@ Default config: ```lua { "php" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/psalm.lua:4](../lua/lspconfig/configs/psalm.lua#L4) +- `root_markers` : + ```lua + { "psalm.xml", "psalm.xml.dist" } + ``` --- @@ -8479,7 +7701,10 @@ Default config: ```lua { "pug" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/pug.lua:2](../lua/lspconfig/configs/pug.lua#L2) +- `root_markers` : + ```lua + { "package.json" } + ``` --- @@ -8514,8 +7739,10 @@ Default config: ```lua { "puppet" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/puppet.lua:11](../lua/lspconfig/configs/puppet.lua#L11) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "manifests", ".puppet-lint.rc", "hiera.yaml", ".git" } + ``` --- @@ -8542,7 +7769,10 @@ Default config: ```lua { "purescript" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/purescriptls.lua:4](../lua/lspconfig/configs/purescriptls.lua#L4) +- `root_markers` : + ```lua + { "bower.json", "flake.nix", "psc-package.json", "shell.nix", "spago.dhall", "spago.yaml" } + ``` --- @@ -8555,10 +7785,10 @@ A Python 3.6+ implementation of the Language Server Protocol. See the [project's README](https://github.com/python-lsp/python-lsp-server) for installation instructions. Configuration options are documented [here](https://github.com/python-lsp/python-lsp-server/blob/develop/CONFIGURATION.md). -In order to configure an option, it must be translated to a nested Lua table and included in the `settings` argument to the `setup{}` function. +In order to configure an option, it must be translated to a nested Lua table and included in the `settings` argument to the `config('pylsp', {})` function. For example, in order to set the `pylsp.plugins.pycodestyle.ignore` option: ```lua -require'lspconfig'.pylsp.setup{ +vim.lsp.config('pylsp', { settings = { pylsp = { plugins = { @@ -8569,7 +7799,7 @@ require'lspconfig'.pylsp.setup{ } } } -} +}) ``` Note: This is a community fork of `pyls`. @@ -8588,8 +7818,10 @@ Default config: ```lua { "python" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/pylsp.lua:4](../lua/lspconfig/configs/pylsp.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "pyproject.toml", "setup.py", "setup.cfg", "requirements.txt", "Pipfile", ".git" } + ``` --- @@ -8597,7 +7829,7 @@ Default config: https://github.com/mtshiba/pylyzer - `pylyzer`, a fast static code analyzer & language server for Python. +`pylyzer`, a fast static code analyzer & language server for Python. Snippet to enable the language server: ```lua @@ -8613,7 +7845,10 @@ Default config: ```lua { "python" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/pylyzer.lua:4](../lua/lspconfig/configs/pylyzer.lua#L4) +- `root_markers` : + ```lua + { "setup.py", "tox.ini", "requirements.txt", "Pipfile", "pyproject.toml", ".git" } + ``` - `settings` : ```lua { @@ -8625,7 +7860,6 @@ Default config: } } ``` -- `single_file_support` : `true` --- @@ -8654,7 +7888,10 @@ Default config: ```lua { "python" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/pyre.lua:4](../lua/lspconfig/configs/pyre.lua#L4) +- `root_markers` : + ```lua + { ".pyre_configuration" } + ``` --- @@ -8669,10 +7906,6 @@ Snippet to enable the language server: require'lspconfig'.pyright.setup{} ``` -Commands: -- PyrightOrganizeImports: Organize Imports -- PyrightSetPythonPath: Reconfigure pyright with the provided python path - Default config: - `cmd` : ```lua @@ -8682,7 +7915,11 @@ Default config: ```lua { "python" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/pyright.lua:44](../lua/lspconfig/configs/pyright.lua#L44) +- `on_attach` source (use "gF" to open): [../lsp/pyright.lua:36](../lsp/pyright.lua#L36) +- `root_markers` : + ```lua + { "pyproject.toml", "setup.py", "setup.cfg", "requirements.txt", "Pipfile", "pyrightconfig.json", ".git" } + ``` - `settings` : ```lua { @@ -8695,7 +7932,6 @@ Default config: } } ``` -- `single_file_support` : `true` --- @@ -8721,8 +7957,10 @@ Default config: ```lua { "qml", "qmljs" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/qmlls.lua:2](../lua/lspconfig/configs/qmlls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -8748,22 +7986,24 @@ Default config: ```lua { "javascript", "typescript" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/quick_lint_js.lua:4](../lua/lspconfig/configs/quick_lint_js.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "package.json", "jsconfig.json", ".git" } + ``` --- ## r_language_server [languageserver](https://github.com/REditorSupport/languageserver) is an -implementation of the Microsoft's Language Server Protocol for the R -language. + implementation of the Microsoft's Language Server Protocol for the R + language. -It is released on CRAN and can be easily installed by + It is released on CRAN and can be easily installed by -```r -install.packages("languageserver") -``` + ```r + install.packages("languageserver") + ``` Snippet to enable the language server: ```lua @@ -8779,11 +8019,7 @@ Default config: ```lua { "r", "rmd", "quarto" } ``` -- `log_level` : - ```lua - 2 - ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/r_language_server.lua:2](../lua/lspconfig/configs/r_language_server.lua#L2) +- `root_dir` source (use "gF" to open): [../lsp/r_language_server.lua:12](../lsp/r_language_server.lua#L12) --- @@ -8791,11 +8027,11 @@ Default config: [https://github.com/jeapostrophe/racket-langserver](https://github.com/jeapostrophe/racket-langserver) -The Racket language server. This project seeks to use -[DrRacket](https://github.com/racket/drracket)'s public API to provide -functionality that mimics DrRacket's code tools as closely as possible. + The Racket language server. This project seeks to use + [DrRacket](https://github.com/racket/drracket)'s public API to provide + functionality that mimics DrRacket's code tools as closely as possible. -Install via `raco`: `raco pkg install racket-langserver` + Install via `raco`: `raco pkg install racket-langserver` Snippet to enable the language server: ```lua @@ -8811,8 +8047,10 @@ Default config: ```lua { "racket", "scheme" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/racket_langserver.lua:2](../lua/lspconfig/configs/racket_langserver.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -8852,8 +8090,10 @@ Default config: ```lua { "raku" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/raku_navigator.lua:2](../lua/lspconfig/configs/raku_navigator.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -8861,7 +8101,7 @@ Default config: Reason language server -You can install reason language server from [reason-language-server](https://github.com/jaredly/reason-language-server) repository. + You can install reason language server from [reason-language-server](https://github.com/jaredly/reason-language-server) repository. Snippet to enable the language server: ```lua @@ -8877,7 +8117,10 @@ Default config: ```lua { "reason" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/reason_ls.lua:4](../lua/lspconfig/configs/reason_ls.lua#L4) +- `root_markers` : + ```lua + { "bsconfig.json", ".git" } + ``` --- @@ -8906,8 +8149,7 @@ Default config: ```lua { "rego" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/regal.lua:4](../lua/lspconfig/configs/regal.lua#L4) -- `single_file_support` : `true` +- `root_dir` source (use "gF" to open): [../lsp/regal.lua:13](../lsp/regal.lua#L13) --- @@ -8936,64 +8178,7 @@ Default config: ```lua { "rego" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/regols.lua:4](../lua/lspconfig/configs/regols.lua#L4) -- `single_file_support` : `true` - ---- - -## relay_lsp - -https://github.com/facebook/relay - `Relay` is a JavaScript framework for building data-driven React applications - - Setup: - - - Make sure you have a Relay config file somewhere in your project. - - We support standard config file formats (`.yml`, `.js`, `.json`), and the the `relay` field in your `package.json` - - Make sure you have the `relay-compiler` installed in your project. The bare minimum is v13. - - Make sure you are able to run the `relay-compiler` command from the command line. If `yarn relay-compiler` works, it's very likely that the LSP will work. - - Remove / disable any conflicting GraphQL LSPs you have installed. - - Relay LSP is a part of the Relay Compiler binary and available when adding `relay-compiler` to your project's devDependencies. - - ```lua - require'lspconfig'.relay_lsp.setup { - -- (default: false) Whether or not we should automatically start - -- the Relay Compiler in watch mode when you open a project - auto_start_compiler = false, - - - -- (default: null) Path to a relay config relative to the - -- `root_dir`. Without this, the compiler will search for your - -- config. This is helpful if your relay project is in a nested - -- directory. - path_to_config = nil, - } - ``` - -Snippet to enable the language server: -```lua -require'lspconfig'.relay_lsp.setup{} -``` - -Default config: -- `auto_start_compiler` : `false` -- `cmd` : - ```lua - { "relay-compiler", "lsp" } - ``` -- `filetypes` : - ```lua - { "javascript", "javascriptreact", "javascript.jsx", "typescript", "typescriptreact", "typescript.tsx" } - ``` -- `handlers` : - ```lua - { - ["window/showStatus"] = <function 1> - } - ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/relay_lsp.lua:5](../lua/lspconfig/configs/relay_lsp.lua#L5) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/relay_lsp.lua:5](../lua/lspconfig/configs/relay_lsp.lua#L5) +- `root_dir` source (use "gF" to open): [../lsp/regols.lua:13](../lsp/regols.lua#L13) --- @@ -9042,8 +8227,10 @@ Default config: ```lua { "markdown" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/remark_ls.lua:4](../lua/lspconfig/configs/remark_ls.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".remarkrc", ".remarkrc.json", ".remarkrc.js", ".remarkrc.cjs", ".remarkrc.mjs", ".remarkrc.yml", ".remarkrc.yaml", ".remarkignore" } + ``` --- @@ -9061,14 +8248,14 @@ for init_options supported. For example, in order to disable the `inlayHints` option: ```lua -require'lspconfig'.pylsp.setup{ +vim.lsp.config('rescriptls', { settings = { rescript = { settings = { inlayHints = { enable = false }, }, }, - } + }) } ``` @@ -9108,7 +8295,10 @@ Default config: } } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/rescriptls.lua:4](../lua/lspconfig/configs/rescriptls.lua#L4) +- `root_markers` : + ```lua + { "bsconfig.json", "rescript.json", ".git" } + ``` - `settings` : ```lua {} @@ -9128,7 +8318,7 @@ All settings listed on the rls configuration section of the readme must be set under settings.rust as follows: ```lua -nvim_lsp.rls.setup { +vim.lsp.config('rls', { settings = { rust = { unstable_features = true, @@ -9136,7 +8326,7 @@ nvim_lsp.rls.setup { all_features = true, }, }, -} +}) ``` If you want to use rls for a particular build, eg nightly, set cmd as follows: @@ -9159,7 +8349,10 @@ Default config: ```lua { "rust" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/rls.lua:4](../lua/lspconfig/configs/rls.lua#L4) +- `root_markers` : + ```lua + { "Cargo.toml" } + ``` --- @@ -9191,7 +8384,7 @@ Default config: ```lua {} ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/rnix.lua:2](../lua/lspconfig/configs/rnix.lua#L2) +- `root_dir` source (use "gF" to open): [../lsp/rnix.lua:10](../lsp/rnix.lua#L10) - `settings` : ```lua {} @@ -9219,9 +8412,11 @@ Default config: ```lua { "robot", "resource" } ``` -- `get_language_id` source (use "gF" to visit): [../lua/lspconfig/configs/robotcode.lua:4](../lua/lspconfig/configs/robotcode.lua#L4) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/robotcode.lua:4](../lua/lspconfig/configs/robotcode.lua#L4) -- `single_file_support` : `true` +- `get_language_id` source (use "gF" to open): [../lsp/robotcode.lua:6](../lsp/robotcode.lua#L6) +- `root_markers` : + ```lua + { "robot.toml", "pyproject.toml", "Pipfile", ".git" } + ``` --- @@ -9245,7 +8440,10 @@ Default config: ```lua { "robot" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/robotframework_ls.lua:4](../lua/lspconfig/configs/robotframework_ls.lua#L4) +- `root_markers` : + ```lua + { "robotidy.toml", "pyproject.toml", "conda.yaml", "robot.yaml", ".git" } + ``` --- @@ -9270,8 +8468,10 @@ Default config: ```lua { "roc" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/roc_ls.lua:2](../lua/lspconfig/configs/roc_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -9301,8 +8501,10 @@ Default config: ```lua { "javascript", "javascriptreact", "json", "typescript", "typescript.tsx", "typescriptreact" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/rome.lua:2](../lua/lspconfig/configs/rome.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "package.json", "node_modules", ".git" } + ``` --- @@ -9326,12 +8528,14 @@ Default config: ```lua { "spec" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/rpmspec.lua:2](../lua/lspconfig/configs/rpmspec.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua {} ``` -- `single_file_support` : `true` --- @@ -9353,7 +8557,10 @@ Default config: ```lua { "ruby" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/rubocop.lua:4](../lua/lspconfig/configs/rubocop.lua#L4) +- `root_markers` : + ```lua + { "Gemfile", ".git" } + ``` --- @@ -9391,8 +8598,10 @@ Default config: formatter = "auto" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ruby_lsp.lua:4](../lua/lspconfig/configs/ruby_lsp.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "Gemfile", ".git" } + ``` --- @@ -9413,7 +8622,7 @@ This is the new built-in language server written in Rust. It supports the same f Server settings can be provided via: ```lua -require('lspconfig').ruff.setup({ +vim.lsp.config('ruff', { init_options = { settings = { -- Server settings should go here @@ -9438,12 +8647,14 @@ Default config: ```lua { "python" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ruff.lua:4](../lua/lspconfig/configs/ruff.lua#L4) +- `root_markers` : + ```lua + { "pyproject.toml", "ruff.toml", ".ruff.toml", ".git" } + ``` - `settings` : ```lua {} ``` -- `single_file_support` : `true` --- @@ -9460,14 +8671,14 @@ pip install ruff-lsp Extra CLI arguments for `ruff` can be provided via ```lua -require'lspconfig'.ruff_lsp.setup{ +vim.lsp.config('ruff_lsp', { init_options = { settings = { -- Any extra CLI arguments for `ruff` go here. args = {}, } } -} +}) ``` Snippet to enable the language server: @@ -9484,12 +8695,14 @@ Default config: ```lua { "python" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ruff_lsp.lua:4](../lua/lspconfig/configs/ruff_lsp.lua#L4) +- `root_markers` : + ```lua + { "pyproject.toml", "ruff.toml", ".git" } + ``` - `settings` : ```lua {} ``` -- `single_file_support` : `true` --- @@ -9514,8 +8727,10 @@ Default config: ```lua { "rune" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/rune_languageserver.lua:2](../lua/lspconfig/configs/rune_languageserver.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -9528,7 +8743,7 @@ rust-analyzer (aka rls 2.0), a language server for Rust See [docs](https://rust-analyzer.github.io/book/configuration.html) for extra settings. The settings can be used like this: ```lua -require'lspconfig'.rust_analyzer.setup{ +vim.lsp.config('rust_analyzer', { settings = { ['rust-analyzer'] = { diagnostics = { @@ -9536,7 +8751,7 @@ require'lspconfig'.rust_analyzer.setup{ } } } -} +}) ``` Note: do not set `init_options` for this LS config, it will be automatically populated by the contents of settings["rust-analyzer"] per @@ -9547,11 +8762,8 @@ Snippet to enable the language server: require'lspconfig'.rust_analyzer.setup{} ``` -Commands: -- CargoReload: Reload current cargo workspace - Default config: -- `before_init` source (use "gF" to visit): [../lua/lspconfig/configs/rust_analyzer.lua:36](../lua/lspconfig/configs/rust_analyzer.lua#L36) +- `before_init` source (use "gF" to open): [../lsp/rust_analyzer.lua:56](../lsp/rust_analyzer.lua#L56) - `capabilities` : ```lua { @@ -9568,20 +8780,20 @@ Default config: ```lua { "rust" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/rust_analyzer.lua:36](../lua/lspconfig/configs/rust_analyzer.lua#L36) -- `single_file_support` : `true` +- `on_attach` source (use "gF" to open): [../lsp/rust_analyzer.lua:56](../lsp/rust_analyzer.lua#L56) +- `root_dir` source (use "gF" to open): [../lsp/rust_analyzer.lua:56](../lsp/rust_analyzer.lua#L56) --- ## salt_ls Language server for Salt configuration files. -https://github.com/dcermak/salt-lsp + https://github.com/dcermak/salt-lsp -The language server can be installed with `pip`: -```sh -pip install salt-lsp -``` + The language server can be installed with `pip`: + ```sh + pip install salt-lsp + ``` Snippet to enable the language server: ```lua @@ -9597,8 +8809,10 @@ Default config: ```lua { "sls" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/salt_ls.lua:2](../lua/lspconfig/configs/salt_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -9622,8 +8836,10 @@ Default config: ```lua { "scheme" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/scheme_langserver.lua:9](../lua/lspconfig/configs/scheme_langserver.lua#L9) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "Akku.manifest", ".git" } + ``` --- @@ -9647,8 +8863,10 @@ Default config: ```lua { "crystal" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/scry.lua:4](../lua/lspconfig/configs/scry.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "shard.yml", ".git" } + ``` --- @@ -9672,7 +8890,10 @@ Default config: ```lua { "lua" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/selene3p_ls.lua:4](../lua/lspconfig/configs/selene3p_ls.lua#L4) +- `root_markers` : + ```lua + { "selene.toml" } + ``` --- @@ -9680,8 +8901,8 @@ Default config: https://github.com/Pure-D/serve-d - `Microsoft language server protocol implementation for D using workspace-d.` - Download a binary from https://github.com/Pure-D/serve-d/releases and put it in your $PATH. +Microsoft language server protocol implementation for D using workspace-d. +Download a binary from https://github.com/Pure-D/serve-d/releases and put it in your $PATH. Snippet to enable the language server: ```lua @@ -9697,7 +8918,10 @@ Default config: ```lua { "d" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/serve_d.lua:4](../lua/lspconfig/configs/serve_d.lua#L4) +- `root_markers` : + ```lua + { "dub.json", "dub.sdl", ".git" } + ``` --- @@ -9725,7 +8949,10 @@ Default config: ```lua { "liquid" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/shopify_theme_ls.lua:11](../lua/lspconfig/configs/shopify_theme_ls.lua#L11) +- `root_markers` : + ```lua + { ".shopifyignore", ".theme-check.yml", ".theme-check.yaml", "shopify.theme.toml" } + ``` - `settings` : ```lua {} @@ -9767,7 +8994,6 @@ Default config: ```lua { "sixtyfps" } ``` -- `single_file_support` : `true` --- @@ -9781,7 +9007,7 @@ by [building `slang` from source](https://github.com/shader-slang/slang/blob/mas The server can be configured by passing a "settings" object to `slangd.setup{}`: ```lua -require('lspconfig').slangd.setup{ +vim.lsp.config('slangd', { settings = { slang = { predefinedMacros = {"MY_VALUE_MACRO=1"}, @@ -9791,7 +9017,7 @@ require('lspconfig').slangd.setup{ } } } -} +}) ``` Available options are documented [here](https://github.com/shader-slang/slang-vscode-extension/tree/main?tab=readme-ov-file#configurations) or in more detail [here](https://github.com/shader-slang/slang-vscode-extension/blob/main/package.json#L70). @@ -9810,8 +9036,10 @@ Default config: ```lua { "hlsl", "shaderslang" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/slangd.lua:8](../lua/lspconfig/configs/slangd.lua#L8) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -9847,8 +9075,10 @@ Default config: ```lua { "slint" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/slint_lsp.lua:2](../lua/lspconfig/configs/slint_lsp.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -9882,7 +9112,7 @@ Default config: ```lua {} ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/smarty_ls.lua:4](../lua/lspconfig/configs/smarty_ls.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/smarty_ls.lua:14](../lsp/smarty_ls.lua#L14) - `settings` : ```lua { @@ -9917,8 +9147,10 @@ Default config: ```lua { "smithy" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/smithy_ls.lua:7](../lua/lspconfig/configs/smithy_ls.lua#L7) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "smithy-build.json", "build.gradle", "build.gradle.kts", ".git" } + ``` --- @@ -9945,7 +9177,10 @@ Default config: ```lua { "ss" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/snakeskin_ls.lua:4](../lua/lspconfig/configs/snakeskin_ls.lua#L4) +- `root_markers` : + ```lua + { "package.json" } + ``` --- @@ -9975,12 +9210,14 @@ Default config: activateSnykCode = "true" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/snyk_ls.lua:4](../lua/lspconfig/configs/snyk_ls.lua#L4) +- `root_markers` : + ```lua + { ".git", ".snyk" } + ``` - `settings` : ```lua {} ``` -- `single_file_support` : `true` --- @@ -9988,14 +9225,14 @@ Default config: A language server for Solidity -See the [documentation](https://solang.readthedocs.io/en/latest/installing.html) for installation instructions. + See the [documentation](https://solang.readthedocs.io/en/latest/installing.html) for installation instructions. -The language server only provides the following capabilities: -* Syntax highlighting -* Diagnostics -* Hover + The language server only provides the following capabilities: + * Syntax highlighting + * Diagnostics + * Hover -There is currently no support for completion, goto definition, references, or other functionality. + There is currently no support for completion, goto definition, references, or other functionality. Snippet to enable the language server: ```lua @@ -10011,7 +9248,10 @@ Default config: ```lua { "solidity" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/solang.lua:2](../lua/lspconfig/configs/solang.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -10047,7 +9287,10 @@ Default config: formatting = true } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/solargraph.lua:4](../lua/lspconfig/configs/solargraph.lua#L4) +- `root_markers` : + ```lua + { "Gemfile", ".git" } + ``` - `settings` : ```lua { @@ -10079,7 +9322,7 @@ Default config: ```lua { "solidity" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/solc.lua:4](../lua/lspconfig/configs/solc.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/solc.lua:8](../lsp/solc.lua#L8) --- @@ -10093,8 +9336,8 @@ Make sure that solc is installed and it's the same version of the file. solc-se Solidity language server is a LSP with autocomplete, go to definition and diagnostics. -If you use brownie, use this root_dir: -root_dir = util.root_pattern('brownie-config.yaml', '.git') +If you use brownie, use this root_markers: +root_markers = { 'brownie-config.yaml', '.git' } on includePath, you can add an extra path to search for external libs, on remapping you can remap lib <> path, like: @@ -10103,10 +9346,10 @@ on includePath, you can add an extra path to search for external libs, on remapp ``` **For brownie users** -Change the root_dir to: +Change the root_markers to: ```lua -root_pattern("brownie-config.yaml", ".git") +root_markers = { 'brownie-config.yaml', '.git' } ``` The best way of using it is to have a package.json in your project folder with the packages that you will use. @@ -10132,7 +9375,10 @@ Default config: ```lua { "solidity" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/solidity.lua:4](../lua/lspconfig/configs/solidity.lua#L4) +- `root_markers` : + ```lua + { ".git", "package.json" } + ``` - `settings` : ```lua { @@ -10171,8 +9417,10 @@ Default config: ```lua { "solidity" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/solidity_ls.lua:14](../lua/lspconfig/configs/solidity_ls.lua#L14) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "hardhat.config.js", "hardhat.config.ts", "foundry.toml", "remappings.txt", "truffle.js", "truffle-config.js", "ape-config.yaml", ".git", "package.json" } + ``` --- @@ -10202,8 +9450,10 @@ Default config: ```lua { "solidity" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/solidity_ls_nomicfoundation.lua:14](../lua/lspconfig/configs/solidity_ls_nomicfoundation.lua#L14) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "hardhat.config.js", "hardhat.config.ts", "foundry.toml", "remappings.txt", "truffle.js", "truffle-config.js", "ape-config.yaml", ".git", "package.json" } + ``` --- @@ -10243,7 +9493,10 @@ Default config: ```lua "somesass_ls" ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/somesass_ls.lua:4](../lua/lspconfig/configs/somesass_ls.lua#L4) +- `root_markers` : + ```lua + { ".git", ".package.json" } + ``` - `settings` : ```lua { @@ -10252,7 +9505,6 @@ Default config: } } ``` -- `single_file_support` : `true` --- @@ -10283,7 +9535,10 @@ Default config: ```lua { "ruby" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/sorbet.lua:4](../lua/lspconfig/configs/sorbet.lua#L4) +- `root_markers` : + ```lua + { "Gemfile", ".git" } + ``` --- @@ -10323,62 +9578,8 @@ Default config: ```lua { "swift", "objc", "objcpp", "c", "cpp" } ``` -- `get_language_id` source (use "gF" to visit): [../lua/lspconfig/configs/sourcekit.lua:4](../lua/lspconfig/configs/sourcekit.lua#L4) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/sourcekit.lua:4](../lua/lspconfig/configs/sourcekit.lua#L4) - ---- - -## sourcery - -https://github.com/sourcery-ai/sourcery - -Refactor Python instantly using the power of AI. - -It requires the init_options param to be populated as shown below and will respond with the list of ServerCapabilities that it supports: - -```lua -require'lspconfig'.sourcery.setup { - init_options = { - --- The Sourcery token for authenticating the user. - --- This is retrieved from the Sourcery website and must be - --- provided by each user. The extension must provide a - --- configuration option for the user to provide this value. - token = <YOUR_TOKEN>, - - --- The extension's name and version as defined by the extension. - extension_version = 'vim.lsp', - - --- The editor's name and version as defined by the editor. - editor_version = 'vim', - }, -} -``` - -Alternatively, you can login to sourcery by running `sourcery login` with sourcery-cli. - -Snippet to enable the language server: -```lua -require'lspconfig'.sourcery.setup{} -``` - -Default config: -- `cmd` : - ```lua - { "sourcery", "lsp" } - ``` -- `filetypes` : - ```lua - { "javascript", "javascriptreact", "python", "typescript", "typescriptreact" } - ``` -- `init_options` : - ```lua - { - editor_version = "vim", - extension_version = "vim.lsp" - } - ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/sourcery.lua:32](../lua/lspconfig/configs/sourcery.lua#L32) -- `single_file_support` : `true` +- `get_language_id` source (use "gF" to open): [../lsp/sourcekit.lua:8](../lsp/sourcekit.lua#L8) +- `root_dir` source (use "gF" to open): [../lsp/sourcekit.lua:8](../lsp/sourcekit.lua#L8) --- @@ -10407,7 +9608,10 @@ Default config: ```lua { "yaml", "json", "yml" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/spectral.lua:6](../lua/lspconfig/configs/spectral.lua#L6) +- `root_markers` : + ```lua + { ".spectral.yaml", ".spectral.yml", ".spectral.json", ".spectral.js" } + ``` - `settings` : ```lua { @@ -10416,7 +9620,6 @@ Default config: validateLanguages = { "yaml", "json", "yml" } } ``` -- `single_file_support` : `true` --- @@ -10452,8 +9655,10 @@ Default config: ```lua { "mcfunction" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/spyglassmc_language_server.lua:4](../lua/lspconfig/configs/spyglassmc_language_server.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "pack.mcmeta" } + ``` --- @@ -10478,7 +9683,10 @@ Default config: ```lua { "sql", "mysql" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/sqlls.lua:4](../lua/lspconfig/configs/sqlls.lua#L4) +- `root_markers` : + ```lua + { ".sqllsrc.json" } + ``` - `settings` : ```lua {} @@ -10491,10 +9699,10 @@ Default config: https://github.com/sqls-server/sqls ```lua -require'lspconfig'.sqls.setup{ +vim.lsp.config('sqls', { cmd = {"path/to/command", "-config", "path/to/config.yml"}; ... -} +}) ``` Sqls can be installed via `go get github.com/sqls-server/sqls`. Instructions for compiling Sqls from the source can be found at [sqls-server/sqls](https://github.com/sqls-server/sqls). @@ -10512,12 +9720,14 @@ Default config: ```lua { "sql", "mysql" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/sqls.lua:4](../lua/lspconfig/configs/sqls.lua#L4) +- `root_markers` : + ```lua + { "config.yml" } + ``` - `settings` : ```lua {} ``` -- `single_file_support` : `true` --- @@ -10541,7 +9751,10 @@ Default config: ```lua { "ruby" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/standardrb.lua:4](../lua/lspconfig/configs/standardrb.lua#L4) +- `root_markers` : + ```lua + { "Gemfile", ".git" } + ``` --- @@ -10569,7 +9782,10 @@ Default config: ```lua { "star", "bzl", "BUILD.bazel" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/starlark_rust.lua:2](../lua/lspconfig/configs/starlark_rust.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -10593,7 +9809,10 @@ Default config: ```lua { "bzl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/starpls.lua:4](../lua/lspconfig/configs/starpls.lua#L4) +- `root_markers` : + ```lua + { "WORKSPACE", "WORKSPACE.bazel", "MODULE.bazel" } + ``` --- @@ -10617,8 +9836,10 @@ Default config: ```lua { "nix" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/statix.lua:4](../lua/lspconfig/configs/statix.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "flake.nix", ".git" } + ``` --- @@ -10644,7 +9865,10 @@ Default config: ```lua { "ruby", "eruby" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/steep.lua:4](../lua/lspconfig/configs/steep.lua#L4) +- `root_markers` : + ```lua + { "Steepfile", ".git" } + ``` --- @@ -10678,7 +9902,10 @@ Default config: ```lua { "html", "ruby", "eruby", "blade", "php" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/stimulus_ls.lua:4](../lua/lspconfig/configs/stimulus_ls.lua#L4) +- `root_markers` : + ```lua + { "Gemfile", ".git" } + ``` --- @@ -10695,13 +9922,13 @@ npm i -g stylelint-lsp Can be configured by passing a `settings.stylelintplus` object to `stylelint_lsp.setup`: ```lua -require'lspconfig'.stylelint_lsp.setup{ +vim.lsp.config('stylelint_lsp', { settings = { stylelintplus = { -- see available options in stylelint-lsp documentation } } -} +}) ``` Snippet to enable the language server: @@ -10718,7 +9945,10 @@ Default config: ```lua { "astro", "css", "html", "less", "scss", "sugarss", "vue", "wxss" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/stylelint_lsp.lua:19](../lua/lspconfig/configs/stylelint_lsp.lua#L19) +- `root_markers` : + ```lua + { ".stylelintrc", ".stylelintrc.mjs", ".stylelintrc.cjs", ".stylelintrc.js", ".stylelintrc.json", ".stylelintrc.yaml", ".stylelintrc.yml", "stylelint.config.mjs", "stylelint.config.cjs", "stylelint.config.js" } + ``` - `settings` : ```lua {} @@ -10746,7 +9976,10 @@ Default config: ```lua { "lua" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/stylua3p_ls.lua:4](../lua/lspconfig/configs/stylua3p_ls.lua#L4) +- `root_markers` : + ```lua + { ".stylua.toml", "stylua.toml" } + ``` --- @@ -10763,9 +9996,9 @@ If you want to disable HTML support for another HTML LSP, add the following to your configuration: ```lua -require'lspconfig'.superhtml.setup { +vim.lsp.config('superhtml', { filetypes = { 'superhtml' } -} +}) ``` Snippet to enable the language server: @@ -10782,8 +10015,10 @@ Default config: ```lua { "superhtml", "html" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/superhtml.lua:2](../lua/lspconfig/configs/superhtml.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -10803,9 +10038,6 @@ Snippet to enable the language server: require'lspconfig'.svelte.setup{} ``` -Commands: -- MigrateToSvelte5: Migrate Component to Svelte 5 Syntax - Default config: - `cmd` : ```lua @@ -10815,7 +10047,11 @@ Default config: ```lua { "svelte" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/svelte.lua:17](../lua/lspconfig/configs/svelte.lua#L17) +- `on_attach` source (use "gF" to open): [../lsp/svelte.lua:24](../lsp/svelte.lua#L24) +- `root_markers` : + ```lua + { "package.json", ".git" } + ``` --- @@ -10836,10 +10072,6 @@ Snippet to enable the language server: require'lspconfig'.svlangserver.setup{} ``` -Commands: -- SvlangserverBuildIndex: Instructs language server to rerun indexing -- SvlangserverReportHierarchy: Generates hierarchy for the given module - Default config: - `cmd` : ```lua @@ -10849,7 +10081,11 @@ Default config: ```lua { "verilog", "systemverilog" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/svlangserver.lua:19](../lua/lspconfig/configs/svlangserver.lua#L19) +- `on_attach` source (use "gF" to open): [../lsp/svlangserver.lua:27](../lsp/svlangserver.lua#L27) +- `root_markers` : + ```lua + { ".svlangserver", ".git" } + ``` - `settings` : ```lua { @@ -10858,7 +10094,6 @@ Default config: } } ``` -- `single_file_support` : `true` --- @@ -10887,7 +10122,10 @@ Default config: ```lua { "verilog", "systemverilog" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/svls.lua:2](../lua/lspconfig/configs/svls.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -10911,7 +10149,10 @@ Default config: ```lua { "meson" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/swift_mesonls.lua:4](../lua/lspconfig/configs/swift_mesonls.lua#L4) +- `root_markers` : + ```lua + { "meson.build", "meson_options.txt", "meson.options", ".git" } + ``` --- @@ -10944,7 +10185,10 @@ Default config: ```lua { "ruby" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/syntax_tree.lua:4](../lua/lspconfig/configs/syntax_tree.lua#L4) +- `root_markers` : + ```lua + { ".streerc", "Gemfile", ".git" } + ``` --- @@ -10973,8 +10217,10 @@ Default config: ```lua { "systemd" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/systemd_ls.lua:2](../lua/lspconfig/configs/systemd_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -11004,59 +10250,9 @@ Default config: ```lua {} ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/tabby_ml.lua:2](../lua/lspconfig/configs/tabby_ml.lua#L2) -- `single_file_support` : `true` - ---- - -## tailwindcss - -https://github.com/tailwindlabs/tailwindcss-intellisense - -Tailwind CSS Language Server can be installed via npm: -```sh -npm install -g @tailwindcss/language-server -``` - -Snippet to enable the language server: -```lua -require'lspconfig'.tailwindcss.setup{} -``` - -Default config: -- `cmd` : +- `root_markers` : ```lua - { "tailwindcss-language-server", "--stdio" } - ``` -- `filetypes` : - ```lua - { "aspnetcorerazor", "astro", "astro-markdown", "blade", "clojure", "django-html", "htmldjango", "edge", "eelixir", "elixir", "ejs", "erb", "eruby", "gohtml", "gohtmltmpl", "haml", "handlebars", "hbs", "html", "htmlangular", "html-eex", "heex", "jade", "leaf", "liquid", "markdown", "mdx", "mustache", "njk", "nunjucks", "php", "razor", "slim", "twig", "css", "less", "postcss", "sass", "scss", "stylus", "sugarss", "javascript", "javascriptreact", "reason", "rescript", "typescript", "typescriptreact", "vue", "svelte", "templ" } - ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/tailwindcss.lua:4](../lua/lspconfig/configs/tailwindcss.lua#L4) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/tailwindcss.lua:4](../lua/lspconfig/configs/tailwindcss.lua#L4) -- `settings` : - ```lua - { - tailwindCSS = { - classAttributes = { "class", "className", "class:list", "classList", "ngClass" }, - includeLanguages = { - eelixir = "html-eex", - eruby = "erb", - htmlangular = "html", - templ = "html" - }, - lint = { - cssConflict = "warning", - invalidApply = "error", - invalidConfigPath = "error", - invalidScreen = "error", - invalidTailwindDirective = "error", - invalidVariant = "error", - recommendedVariantOrder = "warning" - }, - validate = true - } - } + { ".git" } ``` --- @@ -11086,8 +10282,10 @@ Default config: ```lua { "toml" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/taplo.lua:2](../lua/lspconfig/configs/taplo.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -11113,7 +10311,10 @@ Default config: ```lua { "tablegen" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/tblgen_lsp_server.lua:15](../lua/lspconfig/configs/tblgen_lsp_server.lua#L15) +- `root_markers` : + ```lua + { "tablegen_compile_commands.yml", ".git" } + ``` --- @@ -11145,7 +10346,10 @@ Default config: ```lua { "teal" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/teal_ls.lua:4](../lua/lspconfig/configs/teal_ls.lua#L4) +- `root_markers` : + ```lua + { "tlconfig.lua" } + ``` --- @@ -11169,7 +10373,10 @@ Default config: ```lua { "templ" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/templ.lua:4](../lua/lspconfig/configs/templ.lua#L4) +- `root_markers` : + ```lua + { "go.work", "go.mod", ".git" } + ``` --- @@ -11217,7 +10424,10 @@ Default config: ```lua { "terraform", "hcl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/terraform_lsp.lua:4](../lua/lspconfig/configs/terraform_lsp.lua#L4) +- `root_markers` : + ```lua + { ".terraform", ".git" } + ``` --- @@ -11269,7 +10479,10 @@ Default config: ```lua { "terraform", "terraform-vars" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/terraformls.lua:4](../lua/lspconfig/configs/terraformls.lua#L4) +- `root_markers` : + ```lua + { ".terraform", ".git" } + ``` --- @@ -11286,16 +10499,6 @@ Snippet to enable the language server: require'lspconfig'.texlab.setup{} ``` -Commands: -- TexlabBuild: Build the current buffer -- TexlabCancelBuild: Cancel the current build -- TexlabChangeEnvironment: Change the environment at current position -- TexlabCleanArtifacts: Clean the artifacts -- TexlabCleanAuxiliary: Clean the auxiliary files -- TexlabDependencyGraph: Show the dependency graph -- TexlabFindEnvironments: Find the environments at current position -- TexlabForward: Forward search from current position - Default config: - `cmd` : ```lua @@ -11305,7 +10508,11 @@ Default config: ```lua { "tex", "plaintex", "bib" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/texlab.lua:159](../lua/lspconfig/configs/texlab.lua#L159) +- `on_attach` source (use "gF" to open): [../lsp/texlab.lua:163](../lsp/texlab.lua#L163) +- `root_markers` : + ```lua + { ".git", ".latexmkrc", ".texlabroot", "texlabroot", "Tectonic.toml" } + ``` - `settings` : ```lua { @@ -11333,7 +10540,6 @@ Default config: } } ``` -- `single_file_support` : `true` --- @@ -11364,7 +10570,10 @@ Default config: ```lua { "text", "tex", "org" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/textlsp.lua:2](../lua/lspconfig/configs/textlsp.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua { @@ -11387,7 +10596,6 @@ Default config: } } ``` -- `single_file_support` : `true` --- @@ -11412,7 +10620,10 @@ Default config: ```lua { "terraform" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/tflint.lua:4](../lua/lspconfig/configs/tflint.lua#L4) +- `root_markers` : + ```lua + { ".terraform", ".git", ".tflint.hcl" } + ``` --- @@ -11428,9 +10639,9 @@ https://github.com/Shopify/theme-check#installation If installed via Homebrew, `cmd` must be set to 'theme-check-liquid-server' ```lua -require lspconfig.theme_check.setup { +vim.lsp.config('theme_check, { cmd = { 'theme-check-liquid-server' } -} +}) ``` Snippet to enable the language server: @@ -11447,7 +10658,10 @@ Default config: ```lua { "liquid" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/theme_check.lua:6](../lua/lspconfig/configs/theme_check.lua#L6) +- `root_markers` : + ```lua + { ".theme-check.yml" } + ``` - `settings` : ```lua {} @@ -11475,8 +10689,10 @@ Default config: ```lua { "thrift" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/thriftls.lua:4](../lua/lspconfig/configs/thriftls.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".thrift" } + ``` --- @@ -11506,8 +10722,10 @@ Default config: ```lua { "tiltfile" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/tilt_ls.lua:2](../lua/lspconfig/configs/tilt_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -11537,9 +10755,11 @@ Default config: ```lua { "typst" } ``` -- `on_attach` source (use "gF" to visit): [../lua/lspconfig/configs/tinymist.lua:46](../lua/lspconfig/configs/tinymist.lua#L46) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/tinymist.lua:46](../lua/lspconfig/configs/tinymist.lua#L46) -- `single_file_support` : `true` +- `on_attach` source (use "gF" to open): [../lsp/tinymist.lua:56](../lsp/tinymist.lua#L56) +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -11582,7 +10802,7 @@ adds Vue support to this language server. *IMPORTANT*: It is crucial to ensure that `@vue/typescript-plugin` and `volar `are of identical versions. ```lua -require'lspconfig'.ts_ls.setup{ +vim.lsp.config('ts_ls', { init_options = { plugins = { { @@ -11597,7 +10817,7 @@ require'lspconfig'.ts_ls.setup{ "typescript", "vue", }, -} +}) -- You must make sure volar is setup -- e.g. require'lspconfig'.volar.setup{} @@ -11631,17 +10851,19 @@ Default config: hostInfo = "neovim" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ts_ls.lua:4](../lua/lspconfig/configs/ts_ls.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "tsconfig.json", "jsconfig.json", "package.json", ".git" } + ``` --- ## ts_query_ls https://github.com/ribru17/ts_query_ls -Can be configured by passing a "settings" object to `ts_query_ls.setup{}`: +Can be configured by passing a "settings" object to `vim.lsp.config('ts_query_ls', {})`: ```lua -require('lspconfig').ts_query_ls.setup{ +vim.lsp.config('ts_query_ls', { settings = { parser_install_directories = { -- If using nvim-treesitter with lazy.nvim @@ -11661,7 +10883,7 @@ require('lspconfig').ts_query_ls.setup{ 'languages/src/([^/]+)/[^/]+\\.scm$', }, }, -} +}) ``` Snippet to enable the language server: @@ -11678,7 +10900,10 @@ Default config: ```lua { "query" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ts_query_ls.lua:4](../lua/lspconfig/configs/ts_query_ls.lua#L4) +- `root_markers` : + ```lua + { "queries", ".git" } + ``` - `settings` : ```lua { @@ -11717,7 +10942,10 @@ Default config: ```lua { "typespec" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/tsp_server.lua:4](../lua/lspconfig/configs/tsp_server.lua#L4) +- `root_markers` : + ```lua + { "tspconfig.yaml", ".git" } + ``` --- @@ -11739,7 +10967,10 @@ Default config: ```lua { "ruby", "rust", "javascript", "haskell" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ttags.lua:4](../lua/lspconfig/configs/ttags.lua#L4) +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -11773,7 +11004,10 @@ Default config: ```lua { "html", "ruby", "eruby", "blade", "php" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/turbo_ls.lua:2](../lua/lspconfig/configs/turbo_ls.lua#L2) +- `root_markers` : + ```lua + { "Gemfile", ".git" } + ``` --- @@ -11800,7 +11034,10 @@ Default config: ```lua { "turtle", "ttl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/turtle_ls.lua:28](../lua/lspconfig/configs/turtle_ls.lua#L28) +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -11827,7 +11064,10 @@ Default config: ```lua { "python", "cpp" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/tvm_ffi_navigator.lua:4](../lua/lspconfig/configs/tvm_ffi_navigator.lua#L4) +- `root_markers` : + ```lua + { "pyproject.toml", ".git" } + ``` --- @@ -11854,8 +11094,10 @@ Default config: ```lua { "twig" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/twiggy_language_server.lua:4](../lua/lspconfig/configs/twiggy_language_server.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "composer.json", ".git" } + ``` --- @@ -11879,7 +11121,10 @@ Default config: ```lua { "ruby", "eruby" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/typeprof.lua:4](../lua/lspconfig/configs/typeprof.lua#L4) +- `root_markers` : + ```lua + { "Gemfile", ".git" } + ``` --- @@ -11902,12 +11147,14 @@ Default config: ```lua { "typos-lsp" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/typos_lsp.lua:4](../lua/lspconfig/configs/typos_lsp.lua#L4) +- `root_markers` : + ```lua + { "typos.toml", "_typos.toml", ".typos.toml" } + ``` - `settings` : ```lua {} ``` -- `single_file_support` : `true` --- @@ -11931,8 +11178,10 @@ Default config: ```lua { "typst" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/typst_lsp.lua:2](../lua/lspconfig/configs/typst_lsp.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -11958,7 +11207,10 @@ Default config: ```lua { "uiua" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/uiua.lua:4](../lua/lspconfig/configs/uiua.lua#L4) +- `root_markers` : + ```lua + { "main.ua", ".fmt.ua", ".git" } + ``` --- @@ -11986,7 +11238,10 @@ Default config: ```lua { "ungrammar" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ungrammar_languageserver.lua:2](../lua/lspconfig/configs/ungrammar_languageserver.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua { @@ -12000,7 +11255,6 @@ Default config: } } ``` -- `single_file_support` : `true` --- @@ -12022,7 +11276,7 @@ Default config: ```lua { "unison" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/unison.lua:4](../lua/lspconfig/configs/unison.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/unison.lua:6](../lsp/unison.lua#L6) - `settings` : ```lua {} @@ -12053,7 +11307,10 @@ Default config: ```lua { "erb", "haml", "hbs", "html", "css", "postcss", "javascript", "javascriptreact", "markdown", "ejs", "php", "svelte", "typescript", "typescriptreact", "vue-html", "vue", "sass", "scss", "less", "stylus", "astro", "rescript", "rust" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/unocss.lua:4](../lua/lspconfig/configs/unocss.lua#L4) +- `root_markers` : + ```lua + { "unocss.config.js", "unocss.config.ts", "uno.config.js", "uno.config.ts" } + ``` --- @@ -12087,8 +11344,10 @@ Default config: ```lua { "uvl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/uvls.lua:2](../lua/lspconfig/configs/uvls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -12114,7 +11373,10 @@ Default config: ```lua { "v", "vsh", "vv" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/v_analyzer.lua:4](../lua/lspconfig/configs/v_analyzer.lua#L4) +- `root_markers` : + ```lua + { "v.mod", ".git" } + ``` --- @@ -12122,18 +11384,18 @@ Default config: Vacuum is the worlds fastest OpenAPI 3, OpenAPI 2 / Swagger linter and quality analysis tool. -You can install vacuum using mason or follow the instructions here: https://github.com/daveshanley/vacuum + You can install vacuum using mason or follow the instructions here: https://github.com/daveshanley/vacuum -The file types are not detected automatically, you can register them manually (see below) or override the filetypes: + The file types are not detected automatically, you can register them manually (see below) or override the filetypes: -```lua -vim.filetype.add { - pattern = { - ['openapi.*%.ya?ml'] = 'yaml.openapi', - ['openapi.*%.json'] = 'json.openapi', - }, -} -``` + ```lua + vim.filetype.add { + pattern = { + ['openapi.*%.ya?ml'] = 'yaml.openapi', + ['openapi.*%.json'] = 'json.openapi', + }, + } + ``` Snippet to enable the language server: ```lua @@ -12149,8 +11411,10 @@ Default config: ```lua { "yaml.openapi", "json.openapi" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/vacuum.lua:2](../lua/lspconfig/configs/vacuum.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -12172,8 +11436,7 @@ Default config: ```lua { "vala", "genie" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/vala_ls.lua:25](../lua/lspconfig/configs/vala_ls.lua#L25) -- `single_file_support` : `true` +- `root_dir` source (use "gF" to open): [../lsp/vala_ls.lua:27](../lsp/vala_ls.lua#L27) --- @@ -12197,85 +11460,10 @@ Default config: ```lua { "markdown", "text", "tex", "rst" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/vale_ls.lua:4](../lua/lspconfig/configs/vale_ls.lua#L4) -- `single_file_support` : `true` - ---- - -## vdmj - -https://github.com/nickbattle/vdmj - -The VDMJ language server can be installed by cloning the VDMJ repository and -running `mvn clean install`. - -Various options are provided to configure the language server (see below). In -particular: -- `annotation_paths` is a list of folders and/or jar file paths for annotations -that should be used with the language server; -- any value of `debugger_port` less than zero will disable the debugger; note -that if a non-zero value is used, only one instance of the server can be active -at a time. - -More settings for VDMJ can be changed in a file called `vdmj.properties` under -`root_dir/.vscode`. For a description of the available settings, see -[Section 7 of the VDMJ User Guide](https://raw.githubusercontent.com/nickbattle/vdmj/master/vdmj/documentation/UserGuide.pdf). - -Note: proof obligations and combinatorial testing are not currently supported -by neovim. - -Snippet to enable the language server: -```lua -require'lspconfig'.vdmj.setup{} -``` - -Default config: -- `cmd` : - ```lua - { "java" } - ``` -- `filetypes` : - ```lua - { "vdmsl", "vdmpp", "vdmrt" } - ``` -- `options` : - ```lua - { - annotation_paths = {}, - debugger_port = -1, - high_precision = false, - java = "/usr/lib/jvm/temurin-17-jdk-amd64/bin/java", - java_opts = { "-Xmx3000m", "-Xss1m" }, - logfile = "/home/user/.cache/nvim/vdm-lsp.log", - mavenrepo = "/home/user/.m2/repository/com/fujitsu" - } - ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/vdmj.lua:44](../lua/lspconfig/configs/vdmj.lua#L44) - ---- - -## vectorcode_server - -https://github.com/Davidyz/VectorCode - -A Language Server Protocol implementation for VectorCode, a code repository indexing tool. - -Snippet to enable the language server: -```lua -require'lspconfig'.vectorcode_server.setup{} -``` - -Default config: -- `cmd` : - ```lua - { "vectorcode-server" } - ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/vectorcode_server.lua:2](../lua/lspconfig/configs/vectorcode_server.lua#L2) -- `settings` : +- `root_markers` : ```lua - {} + { ".vale.ini" } ``` -- `single_file_support` : `false` --- @@ -12304,7 +11492,10 @@ Default config: ```lua { "systemverilog", "verilog" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/verible.lua:2](../lua/lspconfig/configs/verible.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -12340,7 +11531,10 @@ Default config: ```lua { "systemverilog", "verilog" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/veridian.lua:2](../lua/lspconfig/configs/veridian.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -12369,7 +11563,10 @@ Default config: ```lua { "veryl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/veryl_ls.lua:2](../lua/lspconfig/configs/veryl_ls.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -12416,8 +11613,10 @@ Default config: ```lua { "vhd", "vhdl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/vhdl_ls.lua:9](../lua/lspconfig/configs/vhdl_ls.lua#L9) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "vhdl_ls.toml", ".vhdl_ls.toml" } + ``` --- @@ -12466,8 +11665,10 @@ Default config: vimruntime = "" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/vimls.lua:2](../lua/lspconfig/configs/vimls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -12482,13 +11683,13 @@ For manual installation, download the .vsix archive file from the GitHub releases. Then, configure `cmd` to run the Node script at the unpacked location: ```lua -require'lspconfig'.visualforce_ls.setup { +vim.lsp.config('visualforce_ls', { cmd = { 'node', '/path/to/unpacked/archive/extension/node_modules/@salesforce/salesforcedx-visualforce-language-server/out/src/visualforceServer.js', '--stdio' } -} +}) ``` Snippet to enable the language server: @@ -12510,7 +11711,10 @@ Default config: } } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/visualforce_ls.lua:4](../lua/lspconfig/configs/visualforce_ls.lua#L4) +- `root_markers` : + ```lua + { "sfdx-project.json" } + ``` --- @@ -12536,109 +11740,10 @@ Default config: ```lua { "v", "vlang" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/vls.lua:4](../lua/lspconfig/configs/vls.lua#L4) - ---- - -## volar - -https://github.com/vuejs/language-tools/tree/master/packages/language-server - -Volar language server for Vue - -Volar can be installed via npm: -```sh -npm install -g @vue/language-server -``` - -Volar by default supports Vue 3 projects. -For Vue 2 projects, [additional configuration](https://github.com/vuejs/language-tools/blob/master/extensions/vscode/README.md?plain=1#L19) are required. - -**Hybrid Mode (by default)** - -In this mode, the Vue Language Server exclusively manages the CSS/HTML sections. -You need the `ts_ls` server with the `@vue/typescript-plugin` plugin to support TypeScript in `.vue` files. -See `ts_ls` section for more information - -**No Hybrid Mode** - -Volar will run embedded `ts_ls` therefore there is no need to run it separately. -```lua -local lspconfig = require('lspconfig') - -lspconfig.volar.setup { - -- add filetypes for typescript, javascript and vue - filetypes = { 'typescript', 'javascript', 'javascriptreact', 'typescriptreact', 'vue' }, - init_options = { - vue = { - -- disable hybrid mode - hybridMode = false, - }, - }, -} --- you must remove ts_ls setup --- lspconfig.ts_ls.setup {} -``` - -**Overriding the default TypeScript Server used by Volar** - -The default config looks for TypeScript in the local `node_modules`. This can lead to issues -e.g. when working on a [monorepo](https://monorepo.tools/). The alternatives are: - -- use a global TypeScript Server installation -```lua -require'lspconfig'.volar.setup { - init_options = { - typescript = { - -- replace with your global TypeScript library path - tsdk = '/path/to/node_modules/typescript/lib' - } - } -} -``` - -- use a local server and fall back to a global TypeScript Server installation -```lua -require'lspconfig'.volar.setup { - init_options = { - typescript = { - -- replace with your global TypeScript library path - tsdk = '/path/to/node_modules/typescript/lib' - } - }, - on_new_config = function(new_config, new_root_dir) - local lib_path = vim.fs.find('node_modules/typescript/lib', { path = new_root_dir, upward = true })[1] - if lib_path then - new_config.init_options.typescript.tsdk = lib_path - end - end -} -``` - -Snippet to enable the language server: -```lua -require'lspconfig'.volar.setup{} -``` - -Default config: -- `cmd` : - ```lua - { "vue-language-server", "--stdio" } - ``` -- `filetypes` : +- `root_markers` : ```lua - { "vue" } + { "v.mod", ".git" } ``` -- `init_options` : - ```lua - { - typescript = { - tsdk = "" - } - } - ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/volar.lua:16](../lua/lspconfig/configs/volar.lua#L16) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/volar.lua:16](../lua/lspconfig/configs/volar.lua#L16) --- @@ -12660,8 +11765,10 @@ Default config: ```lua { "coq" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/vscoqtop.lua:4](../lua/lspconfig/configs/vscoqtop.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "_CoqProject", ".git" } + ``` --- @@ -12693,8 +11800,10 @@ Default config: ```lua { "javascript", "javascriptreact", "javascript.jsx", "typescript", "typescriptreact", "typescript.tsx" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/vtsls.lua:4](../lua/lspconfig/configs/vtsls.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "tsconfig.json", "package.json", "jsconfig.json", ".git" } + ``` --- @@ -12763,7 +11872,10 @@ Default config: } } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/vuels.lua:4](../lua/lspconfig/configs/vuels.lua#L4) +- `root_markers` : + ```lua + { "package.json", "vue.config.js" } + ``` --- @@ -12788,7 +11900,6 @@ Default config: ```lua { "wat" } ``` -- `single_file_support` : `true` --- @@ -12815,7 +11926,10 @@ Default config: ```lua { "wgsl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/wgsl_analyzer.lua:4](../lua/lspconfig/configs/wgsl_analyzer.lua#L4) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua {} @@ -12844,11 +11958,11 @@ where the relative filepath is the path relative to the open yaml file, and the is the filepath relative to the filesystem root ('/' on unix systems) 2. Associated a schema url, relative , or absolute (to root of project, not to filesystem root) path to -the a glob pattern relative to the detected project root. Check `:LspInfo` to determine the resolved project +the a glob pattern relative to the detected project root. Check `:checkhealth vim.lsp` to determine the resolved project root. ```lua -require('lspconfig').yamlls.setup { +vim.lsp.config('yamlls', { ... -- other configuration for setup {} settings = { yaml = { @@ -12860,7 +11974,7 @@ require('lspconfig').yamlls.setup { }, }, } -} +}) ``` Currently, kubernetes is special-cased in yammls, see the following upstream issues: @@ -12870,7 +11984,7 @@ Currently, kubernetes is special-cased in yammls, see the following upstream iss To override a schema to use a specific k8s schema version (for example, to use 1.18): ```lua -require('lspconfig').yamlls.setup { +vim.lsp.config('yamlls', { ... -- other configuration for setup {} settings = { yaml = { @@ -12881,7 +11995,7 @@ require('lspconfig').yamlls.setup { }, }, } -} +}) ``` Snippet to enable the language server: @@ -12898,7 +12012,10 @@ Default config: ```lua { "yaml", "yaml.docker-compose", "yaml.gitlab" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/yamlls.lua:2](../lua/lspconfig/configs/yamlls.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua { @@ -12909,7 +12026,6 @@ Default config: } } ``` -- `single_file_support` : `true` --- @@ -12933,7 +12049,10 @@ Default config: ```lua { "yang" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/yang_lsp.lua:2](../lua/lspconfig/configs/yang_lsp.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -12961,8 +12080,10 @@ Default config: ```lua { "yar", "yara" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/yls.lua:2](../lua/lspconfig/configs/yls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -12986,8 +12107,10 @@ Default config: ```lua { "ziggy" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ziggy.lua:2](../lua/lspconfig/configs/ziggy.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -13011,8 +12134,10 @@ Default config: ```lua { "ziggy_schema" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ziggy_schema.lua:2](../lua/lspconfig/configs/ziggy_schema.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` --- @@ -13027,11 +12152,6 @@ Snippet to enable the language server: require'lspconfig'.zk.setup{} ``` -Commands: -- ZkIndex: ZkIndex -- ZkList: ZkList -- ZkNew: ZkNew - Default config: - `cmd` : ```lua @@ -13041,33 +12161,11 @@ Default config: ```lua { "markdown" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/zk.lua:12](../lua/lspconfig/configs/zk.lua#L12) - ---- - -## zls - -https://github.com/zigtools/zls - -Zig LSP implementation + Zig Language Server - -Snippet to enable the language server: -```lua -require'lspconfig'.zls.setup{} -``` - -Default config: -- `cmd` : - ```lua - { "zls" } - ``` -- `filetypes` : +- `on_attach` source (use "gF" to open): [../lsp/zk.lua:14](../lsp/zk.lua#L14) +- `root_markers` : ```lua - { "zig", "zir" } + { ".zk" } ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/zls.lua:4](../lua/lspconfig/configs/zls.lua#L4) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/zls.lua:4](../lua/lspconfig/configs/zls.lua#L4) -- `single_file_support` : `true` --- diff --git a/doc/configs.txt b/doc/configs.txt index 3af3baa0..8cc5a78b 100644 --- a/doc/configs.txt +++ b/doc/configs.txt @@ -15,22 +15,21 @@ https://github.com/AdaCore/ada_language_server Installation instructions can be found [here](https://github.com/AdaCore/ada_language_server#Install). Workspace-specific [settings](https://github.com/AdaCore/ada_language_server/blob/master/doc/settings.md) such as `projectFile` can be provided in a `.als.json` file at the root of the workspace. - -Alternatively, configuration may be passed as a "settings" object to `ada_ls.setup{}`: +Alternatively, configuration may be passed as a "settings" object to `vim.lsp.config('ada_ls', {})`: ```lua -require('lspconfig').ada_ls.setup{ +vim.lsp.config('ada_ls', { settings = { ada = { projectFile = "project.gpr"; scenarioVariables = { ... }; } } -} +}) ``` Snippet to enable the language server: >lua - require'lspconfig'.ada_ls.setup{} + vim.lsp.enable('ada_ls') Default config: @@ -42,7 +41,7 @@ Default config: ```lua { "ada" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ada_ls.lua:4](../lua/lspconfig/configs/ada_ls.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/ada_ls.lua:22](../lsp/ada_ls.lua#L22) ------------------------------------------------------------------------------ @@ -53,7 +52,7 @@ https://github.com/agda/agda-language-server Language Server for Agda. Snippet to enable the language server: >lua - require'lspconfig'.agda_ls.setup{} + vim.lsp.enable('agda_ls') Default config: @@ -65,8 +64,7 @@ Default config: ```lua { "agda" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/agda_ls.lua:4](../lua/lspconfig/configs/agda_ls.lua#L4) -- `single_file_support` : `true` +- `root_dir` source (use "gF" to open): [../lsp/agda_ls.lua:8](../lsp/agda_ls.lua#L8) ------------------------------------------------------------------------------ @@ -80,7 +78,7 @@ A language server for Aiken Programming Language. It can be i Snippet to enable the language server: >lua - require'lspconfig'.aiken.setup{} + vim.lsp.enable('aiken') Default config: @@ -92,7 +90,10 @@ Default config: ```lua { "aiken" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/aiken.lua:4](../lua/lspconfig/configs/aiken.lua#L4) +- `root_markers` : + ```lua + { "aiken.toml", ".git" } + ``` ------------------------------------------------------------------------------ @@ -105,7 +106,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. Snippet to enable the language server: >lua - require'lspconfig'.air.setup{} + vim.lsp.enable('air') Default config: @@ -117,8 +118,10 @@ Default config: ```lua { "r" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/air.lua:2](../lua/lspconfig/configs/air.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "air.toml", ".air.toml", ".git" } + ``` ------------------------------------------------------------------------------ @@ -147,7 +150,7 @@ vim.filetype.add({ Alternatively, you may use a syntax plugin like https://github.com/runoshun/vim-alloy. Snippet to enable the language server: >lua - require'lspconfig'.alloy_ls.setup{} + vim.lsp.enable('alloy_ls') Default config: @@ -159,8 +162,10 @@ Default config: ```lua { "alloy" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/alloy_ls.lua:2](../lua/lspconfig/configs/alloy_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -176,7 +181,7 @@ Available options: * Configuration: https://github.com/muffinmad/anakin-language-server#configuration-options Snippet to enable the language server: >lua - require'lspconfig'.anakin_language_server.setup{} + vim.lsp.enable('anakin_language_server') Default config: @@ -188,7 +193,10 @@ Default config: ```lua { "python" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/anakin_language_server.lua:4](../lua/lspconfig/configs/anakin_language_server.lua#L4) +- `root_markers` : + ```lua + { "pyproject.toml", "setup.py", "setup.cfg", "requirements.txt", "Pipfile", ".git" } + ``` - `settings` : ```lua { @@ -197,44 +205,6 @@ Default config: } } ``` -- `single_file_support` : `true` - - ------------------------------------------------------------------------------- -angularls - -https://github.com/angular/vscode-ng-language-service - -`angular-language-server` can be installed via npm `npm install -g @angular/language-server`. - -Note, that if you override the default `cmd`, you must also update `on_new_config` to set `new_config.cmd` during startup. - -```lua -local project_library_path = "/path/to/project/lib" -local cmd = {"ngserver", "--stdio", "--tsProbeLocations", project_library_path , "--ngProbeLocations", project_library_path} - -require'lspconfig'.angularls.setup{ - cmd = cmd, - on_new_config = function(new_config,new_root_dir) - new_config.cmd = cmd - end, -} -``` - -Snippet to enable the language server: >lua - require'lspconfig'.angularls.setup{} - - -Default config: -- `cmd` : - ```lua - { "ngserver", "--stdio", "--tsProbeLocations", "", "--ngProbeLocations", "", "--angularCoreVersion", "" } - ``` -- `filetypes` : - ```lua - { "typescript", "html", "typescriptreact", "typescript.tsx", "htmlangular" } - ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/angularls.lua:41](../lua/lspconfig/configs/angularls.lua#L41) ------------------------------------------------------------------------------ @@ -251,7 +221,7 @@ npm install -g @ansible/ansible-language-server ``` Snippet to enable the language server: >lua - require'lspconfig'.ansiblels.setup{} + vim.lsp.enable('ansiblels') Default config: @@ -263,7 +233,10 @@ Default config: ```lua { "yaml.ansible" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ansiblels.lua:4](../lua/lspconfig/configs/ansiblels.lua#L4) +- `root_markers` : + ```lua + { "ansible.cfg", ".ansible-lint" } + ``` - `settings` : ```lua { @@ -287,7 +260,6 @@ Default config: } } ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -301,7 +273,7 @@ npm install -g antlers-language-server ``` Snippet to enable the language server: >lua - require'lspconfig'.antlersls.setup{} + vim.lsp.enable('antlersls') Default config: @@ -313,38 +285,10 @@ Default config: ```lua { "html", "antlers" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/antlersls.lua:4](../lua/lspconfig/configs/antlersls.lua#L4) - - ------------------------------------------------------------------------------- -apex_ls - -https://github.com/forcedotcom/salesforcedx-vscode - -Language server for Apex. - -For manual installation, download the JAR file from the [VSCode -extension](https://github.com/forcedotcom/salesforcedx-vscode/tree/develop/packages/salesforcedx-vscode-apex). - -```lua -require'lspconfig'.apex_ls.setup { - apex_jar_path = '/path/to/apex-jorje-lsp.jar', - apex_enable_semantic_errors = false, -- Whether to allow Apex Language Server to surface semantic errors - apex_enable_completion_statistics = false, -- Whether to allow Apex Language Server to collect telemetry on code completion usage -} -``` - -Snippet to enable the language server: >lua - require'lspconfig'.apex_ls.setup{} - - -Default config: -- `filetypes` : +- `root_markers` : ```lua - { "apexcode" } + { "composer.json" } ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/apex_ls.lua:4](../lua/lspconfig/configs/apex_ls.lua#L4) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/apex_ls.lua:4](../lua/lspconfig/configs/apex_ls.lua#L4) ------------------------------------------------------------------------------ @@ -419,7 +363,7 @@ Note that an upstream bug makes keywords in some cases become undefined by the l Ref: https://github.com/arduino/arduino-ide/issues/159 Snippet to enable the language server: >lua - require'lspconfig'.arduino_language_server.setup{} + vim.lsp.enable('arduino_language_server') Default config: @@ -442,7 +386,7 @@ Default config: ```lua { "arduino" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/arduino_language_server.lua:4](../lua/lspconfig/configs/arduino_language_server.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/arduino_language_server.lua:72](../lsp/arduino_language_server.lua#L72) ------------------------------------------------------------------------------ @@ -456,7 +400,7 @@ Language Server for NASM/GAS/GO Assembly cargo install asm-lsp Snippet to enable the language server: >lua - require'lspconfig'.asm_lsp.setup{} + vim.lsp.enable('asm_lsp') Default config: @@ -468,8 +412,10 @@ Default config: ```lua { "asm", "vmasm" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/asm_lsp.lua:2](../lua/lspconfig/configs/asm_lsp.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".asm-lsp.toml", ".git" } + ``` ------------------------------------------------------------------------------ @@ -484,7 +430,7 @@ npm install [-g] @ast-grep/cli ``` Snippet to enable the language server: >lua - require'lspconfig'.ast_grep.setup{} + vim.lsp.enable('ast_grep') Default config: @@ -496,40 +442,10 @@ Default config: ```lua { "c", "cpp", "rust", "go", "java", "python", "javascript", "typescript", "html", "css", "kotlin", "dart", "lua" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ast_grep.lua:4](../lua/lspconfig/configs/ast_grep.lua#L4) - - ------------------------------------------------------------------------------- -astro - -https://github.com/withastro/language-tools/tree/main/packages/language-server - -`astro-ls` can be installed via `npm`: -```sh -npm install -g @astrojs/language-server -``` - -Snippet to enable the language server: >lua - require'lspconfig'.astro.setup{} - - -Default config: -- `cmd` : - ```lua - { "astro-ls", "--stdio" } - ``` -- `filetypes` : +- `root_markers` : ```lua - { "astro" } + { "sgconfig.yaml", "sgconfig.yml" } ``` -- `init_options` : - ```lua - { - typescript = {} - } - ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/astro.lua:9](../lua/lspconfig/configs/astro.lua#L9) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/astro.lua:9](../lua/lspconfig/configs/astro.lua#L9) ------------------------------------------------------------------------------ @@ -586,7 +502,7 @@ vim.treesitter.language.register('hcl', 'atlas-plan') ``` Snippet to enable the language server: >lua - require'lspconfig'.atlas.setup{} + vim.lsp.enable('atlas') Default config: @@ -598,8 +514,10 @@ Default config: ```lua { "atlas-*" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/atlas.lua:4](../lua/lspconfig/configs/atlas.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "atlas.hcl" } + ``` ------------------------------------------------------------------------------ @@ -610,11 +528,10 @@ https://github.com/thqby/vscode-autohotkey2-lsp AutoHotkey v2.0 LSP implementation Snippet to enable the language server: >lua - require'lspconfig'.autohotkey_lsp.setup{} + vim.lsp.enable('autohotkey_lsp') Default config: -- `autostart` : `true` - `cmd` : ```lua { "autohotkey_lsp", "--stdio" } @@ -661,8 +578,10 @@ Default config: locale = "en-us" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/autohotkey_lsp.lua:8](../lua/lspconfig/configs/autohotkey_lsp.lua#L8) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "package.json" } + ``` ------------------------------------------------------------------------------ @@ -678,7 +597,7 @@ pip install autotools-language-server Language server for autoconf, automake and make using tree sitter in python. Snippet to enable the language server: >lua - require'lspconfig'.autotools_ls.setup{} + vim.lsp.enable('autotools_ls') Default config: @@ -690,8 +609,7 @@ Default config: ```lua { "config", "automake", "make" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/autotools_ls.lua:6](../lua/lspconfig/configs/autotools_ls.lua#L6) -- `single_file_support` : `true` +- `root_dir` source (use "gF" to open): [../lsp/autotools_ls.lua:15](../lsp/autotools_ls.lua#L15) ------------------------------------------------------------------------------ @@ -705,7 +623,7 @@ npm install -g awk-language-server ``` Snippet to enable the language server: >lua - require'lspconfig'.awk_ls.setup{} + vim.lsp.enable('awk_ls') Default config: @@ -717,7 +635,6 @@ Default config: ```lua { "awk" } ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -735,7 +652,7 @@ npm install -g azure-pipelines-language-server By default `azure-pipelines-ls` will only work in files named `azure-pipelines.yml`, this can be changed by providing additional settings like so: ```lua -require("lspconfig").azure_pipelines_ls.setup { +vim.lsp.config('azure_pipelines_ls', { ... -- other configuration for setup {} settings = { yaml = { @@ -749,12 +666,12 @@ require("lspconfig").azure_pipelines_ls.setup { }, }, }, -} +}) ``` 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`. Snippet to enable the language server: >lua - require'lspconfig'.azure_pipelines_ls.setup{} + vim.lsp.enable('azure_pipelines_ls') Default config: @@ -766,12 +683,14 @@ Default config: ```lua { "yaml" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/azure_pipelines_ls.lua:4](../lua/lspconfig/configs/azure_pipelines_ls.lua#L4) +- `root_markers` : + ```lua + { "azure-pipelines.yml" } + ``` - `settings` : ```lua {} ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -816,7 +735,7 @@ init_options = { ``` Snippet to enable the language server: >lua - require'lspconfig'.bacon_ls.setup{} + vim.lsp.enable('bacon_ls') Default config: @@ -832,8 +751,10 @@ Default config: ```lua {} ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/bacon_ls.lua:4](../lua/lspconfig/configs/bacon_ls.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".bacon-locations", "Cargo.toml" } + ``` ------------------------------------------------------------------------------ @@ -841,11 +762,11 @@ ballerina Ballerina language server -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. + 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. Snippet to enable the language server: >lua - require'lspconfig'.ballerina.setup{} + vim.lsp.enable('ballerina') Default config: @@ -857,7 +778,10 @@ Default config: ```lua { "ballerina" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ballerina.lua:4](../lua/lspconfig/configs/ballerina.lua#L4) +- `root_markers` : + ```lua + { "Ballerina.toml" } + ``` ------------------------------------------------------------------------------ @@ -868,12 +792,8 @@ https://detachhead.github.io/basedpyright `basedpyright`, a static type checker and language server for python Snippet to enable the language server: >lua - require'lspconfig'.basedpyright.setup{} - + vim.lsp.enable('basedpyright') -Commands: -- PyrightOrganizeImports: Organize Imports -- PyrightSetPythonPath: Reconfigure basedpyright with the provided python path Default config: - `cmd` : @@ -884,7 +804,11 @@ Default config: ```lua { "python" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/basedpyright.lua:44](../lua/lspconfig/configs/basedpyright.lua#L44) +- `on_attach` source (use "gF" to open): [../lsp/basedpyright.lua:36](../lsp/basedpyright.lua#L36) +- `root_markers` : + ```lua + { "pyproject.toml", "setup.py", "setup.cfg", "requirements.txt", "Pipfile", "pyrightconfig.json", ".git" } + ``` - `settings` : ```lua { @@ -897,7 +821,6 @@ Default config: } } ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -913,7 +836,7 @@ npm i -g bash-language-server Language server for bash, written using tree sitter in typescript. Snippet to enable the language server: >lua - require'lspconfig'.bashls.setup{} + vim.lsp.enable('bashls') Default config: @@ -925,7 +848,10 @@ Default config: ```lua { "bash", "sh" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/bashls.lua:2](../lua/lspconfig/configs/bashls.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua { @@ -934,7 +860,6 @@ Default config: } } ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -949,7 +874,7 @@ npm install -g basics-language-server ``` Snippet to enable the language server: >lua - require'lspconfig'.basics_ls.setup{} + vim.lsp.enable('basics_ls') Default config: @@ -973,7 +898,6 @@ Default config: } } ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -994,7 +918,7 @@ vim.filetype.add { ``` Snippet to enable the language server: >lua - require'lspconfig'.bazelrc_lsp.setup{} + vim.lsp.enable('bazelrc_lsp') Default config: @@ -1006,7 +930,10 @@ Default config: ```lua { "bazelrc" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/bazelrc_lsp.lua:4](../lua/lspconfig/configs/bazelrc_lsp.lua#L4) +- `root_markers` : + ```lua + { "WORKSPACE", "WORKSPACE.bazel", "MODULE.bazel" } + ``` ------------------------------------------------------------------------------ @@ -1017,7 +944,7 @@ https://github.com/polarmutex/beancount-language-server#installation See https://github.com/polarmutex/beancount-language-server#configuration for configuration options Snippet to enable the language server: >lua - require'lspconfig'.beancount.setup{} + vim.lsp.enable('beancount') Default config: @@ -1033,8 +960,10 @@ Default config: ```lua {} ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/beancount.lua:2](../lua/lspconfig/configs/beancount.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -1058,10 +987,10 @@ vim.cmd [[ autocmd BufNewFile,BufRead *.bicep set filetype=bicep ]] ```lua local bicep_lsp_bin = "/path/to/bicep-langserver/Bicep.LangServer.dll" -require'lspconfig'.bicep.setup{ +vim.lsp.config('bicep', { cmd = { "dotnet", bicep_lsp_bin }; ... -} +}) ``` To download the latest release and place in /usr/local/bin/bicep-langserver: @@ -1073,7 +1002,7 @@ To download the latest release and place in /usr/local/bin/bicep-langserver: ``` Snippet to enable the language server: >lua - require'lspconfig'.bicep.setup{} + vim.lsp.enable('bicep') Default config: @@ -1085,35 +1014,10 @@ Default config: ```lua {} ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/bicep.lua:2](../lua/lspconfig/configs/bicep.lua#L2) - - ------------------------------------------------------------------------------- -biome - -https://biomejs.dev - -Toolchain of the web. [Successor of Rome](https://biomejs.dev/blog/annoucing-biome). - -```sh -npm install [-g] @biomejs/biome -``` - -Snippet to enable the language server: >lua - require'lspconfig'.biome.setup{} - - -Default config: -- `cmd` : - ```lua - { "biome", "lsp-proxy" } - ``` -- `filetypes` : +- `root_markers` : ```lua - { "astro", "css", "graphql", "javascript", "javascriptreact", "json", "jsonc", "svelte", "typescript", "typescript.tsx", "typescriptreact", "vue" } + { ".git" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/biome.lua:4](../lua/lspconfig/configs/biome.lua#L4) -- `single_file_support` : `false` ------------------------------------------------------------------------------ @@ -1122,7 +1026,7 @@ bitbake_language_server 🛠️ bitbake language server Snippet to enable the language server: >lua - require'lspconfig'.bitbake_language_server.setup{} + vim.lsp.enable('bitbake_language_server') Default config: @@ -1134,38 +1038,10 @@ Default config: ```lua { "bitbake" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/bitbake_language_server.lua:2](../lua/lspconfig/configs/bitbake_language_server.lua#L2) - - ------------------------------------------------------------------------------- -bitbake_ls - -https://github.com/yoctoproject/vscode-bitbake/tree/staging/server -https://www.npmjs.com/package/language-server-bitbake - -Official Bitbake Language Server for the Yocto Project. - -Can be installed from npm or github. - -``` -npm install -g language-server-bitbake -``` - -Snippet to enable the language server: >lua - require'lspconfig'.bitbake_ls.setup{} - - -Default config: -- `cmd` : +- `root_markers` : ```lua - { "language-server-bitbake", "--stdio" } + { ".git" } ``` -- `filetypes` : - ```lua - { "bitbake" } - ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/bitbake_ls.lua:2](../lua/lspconfig/configs/bitbake_ls.lua#L2) -- `single_file_support` : `false` ------------------------------------------------------------------------------ @@ -1179,7 +1055,7 @@ Language server for the blueprint markup language, written in python and part of the blueprint-compiler. Snippet to enable the language server: >lua - require'lspconfig'.blueprint_ls.setup{} + vim.lsp.enable('blueprint_ls') Default config: @@ -1197,8 +1073,10 @@ Default config: ```lua { "blueprint" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/blueprint_ls.lua:2](../lua/lspconfig/configs/blueprint_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -1213,7 +1091,7 @@ $ go install github.com/kitagry/bqls@latest ``` Snippet to enable the language server: >lua - require'lspconfig'.bqls.setup{} + vim.lsp.enable('bqls') Default config: @@ -1225,43 +1103,14 @@ Default config: ```lua { "sql" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/bqls.lua:2](../lua/lspconfig/configs/bqls.lua#L2) -- `settings` : - ```lua - {} - ``` -- `single_file_support` : `true` - - ------------------------------------------------------------------------------- -bqnlsp - -https://git.sr.ht/~detegr/bqnlsp - - -`bqnlsp`, a language server for BQN. - -The binary depends on the shared library of [CBQN](https://github.com/dzaima/CBQN) `libcbqn.so`. -If CBQN is installed system-wide (using `sudo make install` in its source directory) and `bqnlsp` errors that it can't find the shared library, update the linker cache by executing `sudo ldconfig`. -If CBQN has been installed in a non-standard directory or can't be installed globally pass `libcbqnPath = '/path/to/CBQN'` to the setup function. -This will set the environment variables `LD_LIBRARY_PATH` (Linux) or `DYLD_LIBRARY_PATH` (macOS) to the provided path. - -Snippet to enable the language server: >lua - require'lspconfig'.bqnlsp.setup{} - - -Default config: -- `cmd` : +- `root_markers` : ```lua - { "bqnlsp" } + { ".git" } ``` -- `filetypes` : +- `settings` : ```lua - { "bqn" } + {} ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/bqnlsp.lua:14](../lua/lspconfig/configs/bqnlsp.lua#L14) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/bqnlsp.lua:14](../lua/lspconfig/configs/bqnlsp.lua#L14) -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -1275,7 +1124,7 @@ npm install -g brighterscript ``` Snippet to enable the language server: >lua - require'lspconfig'.bright_script.setup{} + vim.lsp.enable('bright_script') Default config: @@ -1287,7 +1136,10 @@ Default config: ```lua { "brs" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/bright_script.lua:4](../lua/lspconfig/configs/bright_script.lua#L4) +- `root_markers` : + ```lua + { "makefile", "Makefile", ".git" } + ``` - `single_file_support` : `true` @@ -1296,10 +1148,10 @@ bsl_ls https://github.com/1c-syntax/bsl-language-server - Language Server Protocol implementation for 1C (BSL) - 1C:Enterprise 8 and OneScript languages. +Language Server Protocol implementation for 1C (BSL) - 1C:Enterprise 8 and OneScript languages. Snippet to enable the language server: >lua - require'lspconfig'.bsl_ls.setup{} + vim.lsp.enable('bsl_ls') Default config: @@ -1307,7 +1159,10 @@ Default config: ```lua { "bsl", "os" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/bsl_ls.lua:2](../lua/lspconfig/configs/bsl_ls.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -1324,7 +1179,7 @@ vim.cmd [[ autocmd BufRead,BufNewFile *.bxl,BUCK,TARGETS set filetype=bzl ]] ``` Snippet to enable the language server: >lua - require'lspconfig'.buck2.setup{} + vim.lsp.enable('buck2') Default config: @@ -1336,7 +1191,10 @@ Default config: ```lua { "bzl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/buck2.lua:4](../lua/lspconfig/configs/buck2.lua#L4) +- `root_markers` : + ```lua + { ".buckconfig" } + ``` ------------------------------------------------------------------------------ @@ -1348,7 +1206,7 @@ supporting new dialects defined in buddy-mlir. `buddy-lsp-server` can be installed at the buddy-mlir repository (buddy-compiler/buddy-mlir) Snippet to enable the language server: >lua - require'lspconfig'.buddy_ls.setup{} + vim.lsp.enable('buddy_ls') Default config: @@ -1360,21 +1218,19 @@ Default config: ```lua { "mlir" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/buddy_ls.lua:2](../lua/lspconfig/configs/buddy_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ buf_ls -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 Snippet to enable the language server: >lua - require'lspconfig'.buf_ls.setup{} + vim.lsp.enable('buf_ls') Default config: @@ -1386,7 +1242,10 @@ Default config: ```lua { "proto" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/buf_ls.lua:2](../lua/lspconfig/configs/buf_ls.lua#L2) +- `root_markers` : + ```lua + { "buf.yaml", ".git" } + ``` ------------------------------------------------------------------------------ @@ -1402,7 +1261,7 @@ go install github.com/bufbuild/buf-language-server/cmd/bufls@latest bufls is a Protobuf language server compatible with Buf modules and workspaces Snippet to enable the language server: >lua - require'lspconfig'.bufls.setup{} + vim.lsp.enable('bufls') Default config: @@ -1414,7 +1273,10 @@ Default config: ```lua { "proto" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/bufls.lua:4](../lua/lspconfig/configs/bufls.lua#L4) +- `root_markers` : + ```lua + { "buf.work.yaml", ".git" } + ``` ------------------------------------------------------------------------------ @@ -1427,7 +1289,7 @@ https://docs.stack.build/docs/cli/installation https://docs.stack.build/docs/vscode/starlark-language-server Snippet to enable the language server: >lua - require'lspconfig'.bzl.setup{} + vim.lsp.enable('bzl') Default config: @@ -1439,7 +1301,10 @@ Default config: ```lua { "bzl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/bzl.lua:4](../lua/lspconfig/configs/bzl.lua#L4) +- `root_markers` : + ```lua + { "WORKSPACE", "WORKSPACE.bazel" } + ``` ------------------------------------------------------------------------------ @@ -1450,7 +1315,7 @@ https://github.com/pherrymason/c3-lsp Language Server for c3. Snippet to enable the language server: >lua - require'lspconfig'.c3_lsp.setup{} + vim.lsp.enable('c3_lsp') Default config: @@ -1462,42 +1327,10 @@ Default config: ```lua { "c3", "c3i" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/c3_lsp.lua:4](../lua/lspconfig/configs/c3_lsp.lua#L4) - - ------------------------------------------------------------------------------- -cadence - -[Cadence Language Server](https://github.com/onflow/cadence-tools/tree/master/languageserver) -using the [flow-cli](https://developers.flow.com/tools/flow-cli). - -The `flow` command from flow-cli must be available. For install instructions see -[the docs](https://developers.flow.com/tools/flow-cli/install#install-the-flow-cli) or the -[Github page](https://github.com/onflow/flow-cli). - -By default the configuration is taken from the closest `flow.json` or the `flow.json` in the users home directory. - -Snippet to enable the language server: >lua - require'lspconfig'.cadence.setup{} - - -Default config: -- `cmd` : +- `root_markers` : ```lua - { "flow", "cadence", "language-server" } + { "project.json", "manifest.json", ".git" } ``` -- `filetypes` : - ```lua - { "cdc" } - ``` -- `init_options` : - ```lua - { - numberOfAccounts = "1" - } - ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/cadence.lua:4](../lua/lspconfig/configs/cadence.lua#L4) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/cadence.lua:4](../lua/lspconfig/configs/cadence.lua#L4) ------------------------------------------------------------------------------ @@ -1505,17 +1338,17 @@ cairo_ls [Cairo Language Server](https://github.com/starkware-libs/cairo/tree/main/crates/cairo-lang-language-server) -First, install Cairo following [this tutorial](https://book.cairo-lang.org/ch01-01-installation.html) + First, install Cairo following [this tutorial](https://book.cairo-lang.org/ch01-01-installation.html) -Then enable Cairo Language Server in your Lua configuration. -```lua -require'lspconfig'.cairo_ls.setup{} -``` + Then enable Cairo Language Server in your Lua configuration. + ```lua + vim.lsp.enable('cairo_ls') + ``` -*cairo-language-server is still under active development, some features might not work yet !* + *cairo-language-server is still under active development, some features might not work yet !* Snippet to enable the language server: >lua - require'lspconfig'.cairo_ls.setup{} + vim.lsp.enable('cairo_ls') Default config: @@ -1533,58 +1366,10 @@ Default config: hostInfo = "neovim" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/cairo_ls.lua:4](../lua/lspconfig/configs/cairo_ls.lua#L4) - - ------------------------------------------------------------------------------- -ccls - -https://github.com/MaskRay/ccls/wiki - -ccls relies on a [JSON compilation database](https://clang.llvm.org/docs/JSONCompilationDatabase.html) specified -as compile_commands.json or, for simpler projects, a .ccls. -For details on how to automatically generate one using CMake look [here](https://cmake.org/cmake/help/latest/variable/CMAKE_EXPORT_COMPILE_COMMANDS.html). Alternatively, you can use [Bear](https://github.com/rizsotto/Bear). - -Customization options are passed to ccls at initialization time via init_options, a list of available options can be found [here](https://github.com/MaskRay/ccls/wiki/Customization#initialization-options). For example: - -```lua -local lspconfig = require'lspconfig' -lspconfig.ccls.setup { - init_options = { - compilationDatabaseDirectory = "build"; - index = { - threads = 0; - }; - clang = { - excludeArgs = { "-frounding-math"} ; - }; - } -} - -``` - -Snippet to enable the language server: >lua - require'lspconfig'.ccls.setup{} - - -Commands: -- CclsSwitchSourceHeader: Switch between source/header - -Default config: -- `cmd` : +- `root_markers` : ```lua - { "ccls" } + { "Scarb.toml", "cairo_project.toml", ".git" } ``` -- `filetypes` : - ```lua - { "c", "cpp", "objc", "objcpp", "cuda" } - ``` -- `offset_encoding` : - ```lua - "utf-32" - ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ccls.lua:24](../lua/lspconfig/configs/ccls.lua#L24) -- `single_file_support` : `false` ------------------------------------------------------------------------------ @@ -1599,7 +1384,7 @@ npm i -g @sap/cds-lsp ``` Snippet to enable the language server: >lua - require'lspconfig'.cds_lsp.setup{} + vim.lsp.enable('cds_lsp') Default config: @@ -1611,7 +1396,10 @@ Default config: ```lua { "cds" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/cds_lsp.lua:4](../lua/lspconfig/configs/cds_lsp.lua#L4) +- `root_markers` : + ```lua + { "package.json", "db", "srv" } + ``` - `settings` : ```lua { @@ -1620,7 +1408,6 @@ Default config: } } ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -1628,10 +1415,10 @@ circom-lsp [Circom Language Server](https://github.com/rubydusa/circom-lsp) -`circom-lsp`, the language server for the Circom language. + `circom-lsp`, the language server for the Circom language. Snippet to enable the language server: >lua - require'lspconfig'.circom-lsp.setup{} + vim.lsp.enable('circom-lsp') Default config: @@ -1643,8 +1430,10 @@ Default config: ```lua { "circom" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/circom-lsp.lua:2](../lua/lspconfig/configs/circom-lsp.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -1662,12 +1451,8 @@ https://clangd.llvm.org/installation.html specified as compile_commands.json, see https://clangd.llvm.org/installation#compile_commandsjson Snippet to enable the language server: >lua - require'lspconfig'.clangd.setup{} - + vim.lsp.enable('clangd') -Commands: -- ClangdShowSymbolInfo: Show symbol info -- ClangdSwitchSourceHeader: Switch between source/header Default config: - `capabilities` : @@ -1689,8 +1474,11 @@ Default config: ```lua { "c", "cpp", "objc", "objcpp", "cuda", "proto" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/clangd.lua:51](../lua/lspconfig/configs/clangd.lua#L51) -- `single_file_support` : `true` +- `on_attach` source (use "gF" to open): [../lsp/clangd.lua:62](../lsp/clangd.lua#L62) +- `root_markers` : + ```lua + { ".clangd", ".clang-tidy", ".clang-format", "compile_commands.json", "compile_flags.txt", "configure.ac", ".git" } + ``` ------------------------------------------------------------------------------ @@ -1698,10 +1486,10 @@ clarity_lsp `clarity-lsp` is a language server for the Clarity language. Clarity is a decidable smart contract language that optimizes for predictability and security. Smart contracts allow developers to encode essential business logic on a blockchain. -To learn how to configure the clarity language server, see the [clarity-lsp documentation](https://github.com/hirosystems/clarity-lsp). + To learn how to configure the clarity language server, see the [clarity-lsp documentation](https://github.com/hirosystems/clarity-lsp). Snippet to enable the language server: >lua - require'lspconfig'.clarity_lsp.setup{} + vim.lsp.enable('clarity_lsp') Default config: @@ -1713,7 +1501,10 @@ Default config: ```lua { "clar", "clarity" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/clarity_lsp.lua:4](../lua/lspconfig/configs/clarity_lsp.lua#L4) +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -1724,7 +1515,7 @@ https://github.com/clojure-lsp/clojure-lsp Clojure Language Server Snippet to enable the language server: >lua - require'lspconfig'.clojure_lsp.setup{} + vim.lsp.enable('clojure_lsp') Default config: @@ -1736,8 +1527,10 @@ Default config: ```lua { "clojure", "edn" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/clojure_lsp.lua:4](../lua/lspconfig/configs/clojure_lsp.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "project.clj", "deps.edn", "build.boot", "shadow-cljs.edn", ".git", "bb.edn" } + ``` ------------------------------------------------------------------------------ @@ -1748,7 +1541,7 @@ https://github.com/regen100/cmake-language-server CMake LSP Implementation Snippet to enable the language server: >lua - require'lspconfig'.cmake.setup{} + vim.lsp.enable('cmake') Default config: @@ -1766,8 +1559,10 @@ Default config: buildDirectory = "build" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/cmake.lua:4](../lua/lspconfig/configs/cmake.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "CMakePresets.json", "CTestConfig.cmake", ".git", "build", "cmake" } + ``` ------------------------------------------------------------------------------ @@ -1776,7 +1571,7 @@ cobol_ls Cobol language support Snippet to enable the language server: >lua - require'lspconfig'.cobol_ls.setup{} + vim.lsp.enable('cobol_ls') Default config: @@ -1788,42 +1583,9 @@ Default config: ```lua { "cobol" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/cobol_ls.lua:2](../lua/lspconfig/configs/cobol_ls.lua#L2) - - ------------------------------------------------------------------------------- -codeqlls - -Reference: -https://codeql.github.com/docs/codeql-cli/ - -Binaries: -https://github.com/github/codeql-cli-binaries - -Snippet to enable the language server: >lua - require'lspconfig'.codeqlls.setup{} - - -Default config: -- `before_init` source (use "gF" to visit): [../lua/lspconfig/configs/codeqlls.lua:6](../lua/lspconfig/configs/codeqlls.lua#L6) -- `cmd` : - ```lua - { "codeql", "execute", "language-server", "--check-errors", "ON_CHANGE", "-q" } - ``` -- `filetypes` : - ```lua - { "ql" } - ``` -- `log_level` : +- `root_markers` : ```lua - 2 - ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/codeqlls.lua:6](../lua/lspconfig/configs/codeqlls.lua#L6) -- `settings` : - ```lua - { - search_path = vim.empty_dict() - } + { ".git" } ``` @@ -1839,7 +1601,7 @@ npm install -g coffeesense-language-server ``` Snippet to enable the language server: >lua - require'lspconfig'.coffeesense.setup{} + vim.lsp.enable('coffeesense') Default config: @@ -1851,8 +1613,10 @@ Default config: ```lua { "coffee" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/coffeesense.lua:4](../lua/lspconfig/configs/coffeesense.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "package.json" } + ``` ------------------------------------------------------------------------------ @@ -1869,7 +1633,7 @@ To install the language server, you need to download the appropriate [GitHub rel After the download unzip the Contextive.LanguageServer binary and copy the file into a folder that is included in your system's PATH. Snippet to enable the language server: >lua - require'lspconfig'.contextive.setup{} + vim.lsp.enable('contextive') Default config: @@ -1877,7 +1641,10 @@ Default config: ```lua { "Contextive.LanguageServer" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/contextive.lua:4](../lua/lspconfig/configs/contextive.lua#L4) +- `root_markers` : + ```lua + { ".contextive", ".git" } + ``` ------------------------------------------------------------------------------ @@ -1886,7 +1653,7 @@ coq_lsp https://github.com/ejgallego/coq-lsp/ Snippet to enable the language server: >lua - require'lspconfig'.coq_lsp.setup{} + vim.lsp.enable('coq_lsp') Default config: @@ -1898,8 +1665,10 @@ Default config: ```lua { "coq" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/coq_lsp.lua:4](../lua/lspconfig/configs/coq_lsp.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "_CoqProject", ".git" } + ``` ------------------------------------------------------------------------------ @@ -1910,7 +1679,7 @@ https://github.com/elbywan/crystalline Crystal language server. Snippet to enable the language server: >lua - require'lspconfig'.crystalline.setup{} + vim.lsp.enable('crystalline') Default config: @@ -1922,8 +1691,10 @@ Default config: ```lua { "crystal" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/crystalline.lua:4](../lua/lspconfig/configs/crystalline.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "shard.yml", ".git" } + ``` ------------------------------------------------------------------------------ @@ -1938,7 +1709,7 @@ csharp-ls requires the [dotnet-sdk](https://dotnet.microsoft.com/download) to be The preferred way to install csharp-ls is with `dotnet tool install --global csharp-ls`. Snippet to enable the language server: >lua - require'lspconfig'.csharp_ls.setup{} + vim.lsp.enable('csharp_ls') Default config: @@ -1956,7 +1727,7 @@ Default config: AutomaticWorkspaceInit = true } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/csharp_ls.lua:4](../lua/lspconfig/configs/csharp_ls.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/csharp_ls.lua:12](../lsp/csharp_ls.lua#L12) ------------------------------------------------------------------------------ @@ -1973,7 +1744,7 @@ npm i -g css-variables-language-server ``` Snippet to enable the language server: >lua - require'lspconfig'.css_variables.setup{} + vim.lsp.enable('css_variables') Default config: @@ -1985,7 +1756,10 @@ Default config: ```lua { "css", "scss", "less" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/css_variables.lua:4](../lua/lspconfig/configs/css_variables.lua#L4) +- `root_markers` : + ```lua + { "package.json", ".git" } + ``` - `settings` : ```lua { @@ -2015,13 +1789,13 @@ Neovim does not currently include built-in snippets. `vscode-css-language-server local capabilities = vim.lsp.protocol.make_client_capabilities() capabilities.textDocument.completion.completionItem.snippetSupport = true -require'lspconfig'.cssls.setup { +vim.lsp.config('cssls', { capabilities = capabilities, -} +}) ``` Snippet to enable the language server: >lua - require'lspconfig'.cssls.setup{} + vim.lsp.enable('cssls') Default config: @@ -2039,7 +1813,10 @@ Default config: provideFormatter = true } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/cssls.lua:4](../lua/lspconfig/configs/cssls.lua#L4) +- `root_markers` : + ```lua + { "package.json", ".git" } + ``` - `settings` : ```lua { @@ -2054,7 +1831,6 @@ Default config: } } ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -2070,7 +1846,7 @@ npm install -g cssmodules-language-server ``` Snippet to enable the language server: >lua - require'lspconfig'.cssmodules_ls.setup{} + vim.lsp.enable('cssmodules_ls') Default config: @@ -2082,7 +1858,10 @@ Default config: ```lua { "javascript", "javascriptreact", "typescript", "typescriptreact" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/cssmodules_ls.lua:2](../lua/lspconfig/configs/cssmodules_ls.lua#L2) +- `root_markers` : + ```lua + { "package.json" } + ``` ------------------------------------------------------------------------------ @@ -2100,7 +1879,7 @@ npm install -g @cucumber/language-server ``` Snippet to enable the language server: >lua - require'lspconfig'.cucumber_language_server.setup{} + vim.lsp.enable('cucumber_language_server') Default config: @@ -2112,7 +1891,10 @@ Default config: ```lua { "cucumber" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/cucumber_language_server.lua:2](../lua/lspconfig/configs/cucumber_language_server.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -2123,7 +1905,7 @@ https://github.com/cue-lang/cue CUE makes it easy to validate data, write schemas, and ensure configurations align with policies. Snippet to enable the language server: >lua - require'lspconfig'.cue.setup{} + vim.lsp.enable('cue') Default config: @@ -2135,8 +1917,10 @@ Default config: ```lua { "cue" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/cue.lua:4](../lua/lspconfig/configs/cue.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "cue.mod", ".git" } + ``` ------------------------------------------------------------------------------ @@ -2167,7 +1951,7 @@ Here's an example that disables type checking in JavaScript files. ``` Snippet to enable the language server: >lua - require'lspconfig'.custom_elements_ls.setup{} + vim.lsp.enable('custom_elements_ls') Default config: @@ -2181,7 +1965,7 @@ Default config: hostInfo = "neovim" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/custom_elements_ls.lua:4](../lua/lspconfig/configs/custom_elements_ls.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/custom_elements_ls.lua:26](../lsp/custom_elements_ls.lua#L26) ------------------------------------------------------------------------------ @@ -2198,7 +1982,7 @@ npm i -g @neo4j-cypher/language-server ``` Snippet to enable the language server: >lua - require'lspconfig'.cypher_ls.setup{} + vim.lsp.enable('cypher_ls') Default config: @@ -2210,8 +1994,10 @@ Default config: ```lua { "cypher" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/cypher_ls.lua:2](../lua/lspconfig/configs/cypher_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -2220,7 +2006,7 @@ daedalus_ls Snippet to enable the language server: >lua - require'lspconfig'.daedalus_ls.setup{} + vim.lsp.enable('daedalus_ls') Default config: @@ -2232,7 +2018,10 @@ Default config: ```lua { "d" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/daedalus_ls.lua:14](../lua/lspconfig/configs/daedalus_ls.lua#L14) +- `root_markers` : + ```lua + { "Gothic.src", "Camera.src", "Menu.src", "Music.src", "ParticleFX.src", "SFX.src", "VisualFX.src" } + ``` - `settings` : ```lua { @@ -2254,13 +2043,8 @@ dafny Support for the Dafny language server. - The default `cmd` uses "dafny server", which works on Dafny 4.0.0+. For - older versions of Dafny, you can compile the language server from source at - [dafny-lang/language-server-csharp](https://github.com/dafny-lang/language-server-csharp) - and set `cmd = {"dotnet", "<Path to your language server>"}`. - Snippet to enable the language server: >lua - require'lspconfig'.dafny.setup{} + vim.lsp.enable('dafny') Default config: @@ -2272,8 +2056,10 @@ Default config: ```lua { "dfy", "dafny" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/dafny.lua:2](../lua/lspconfig/configs/dafny.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -2284,7 +2070,7 @@ https://github.com/dagger/cuelsp Dagger's lsp server for cuelang. Snippet to enable the language server: >lua - require'lspconfig'.dagger.setup{} + vim.lsp.enable('dagger') Default config: @@ -2296,8 +2082,10 @@ Default config: ```lua { "cue" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/dagger.lua:4](../lua/lspconfig/configs/dagger.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "cue.mod", ".git" } + ``` ------------------------------------------------------------------------------ @@ -2308,7 +2096,7 @@ https://github.com/dart-lang/sdk/tree/master/pkg/analysis_server/tool/lsp_spec Language server for dart. Snippet to enable the language server: >lua - require'lspconfig'.dartls.setup{} + vim.lsp.enable('dartls') Default config: @@ -2330,7 +2118,10 @@ Default config: suggestFromUnimportedLibraries = true } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/dartls.lua:4](../lua/lspconfig/configs/dartls.lua#L4) +- `root_markers` : + ```lua + { "pubspec.yaml" } + ``` - `settings` : ```lua { @@ -2350,7 +2141,7 @@ https://dcm.dev/ Language server for DCM analyzer. Snippet to enable the language server: >lua - require'lspconfig'.dcmls.setup{} + vim.lsp.enable('dcmls') Default config: @@ -2362,7 +2153,10 @@ Default config: ```lua { "dart" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/dcmls.lua:4](../lua/lspconfig/configs/dcmls.lua#L4) +- `root_markers` : + ```lua + { "pubspec.yaml" } + ``` ------------------------------------------------------------------------------ @@ -2373,7 +2167,7 @@ https://salsa.debian.org/debian/debputy Language Server for Debian packages. Snippet to enable the language server: >lua - require'lspconfig'.debputy.setup{} + vim.lsp.enable('debputy') Default config: @@ -2385,63 +2179,10 @@ Default config: ```lua { "debcontrol", "debcopyright", "debchangelog", "make", "yaml" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/debputy.lua:4](../lua/lspconfig/configs/debputy.lua#L4) - - ------------------------------------------------------------------------------- -delphi_ls - -Language server for Delphi from Embarcadero. -https://marketplace.visualstudio.com/items?itemName=EmbarcaderoTechnologies.delphilsp - -Note, the '*.delphilsp.json' file is required, more details at: -https://docwiki.embarcadero.com/RADStudio/Alexandria/en/Using_DelphiLSP_Code_Insight_with_Other_Editors - -Below, you'll find a sample configuration for the lazy manager. -When on_attach is triggered, it signals DelphiLSP to load settings from a configuration file. -Without this step, DelphiLSP initializes but remains non-functional: - -```lua -"neovim/nvim-lspconfig", -lazy = false, -config = function() - local capabilities = require("cmp_nvim_lsp").default_capabilities() - local lspconfig = require("lspconfig") - - lspconfig.delphi_ls.setup({ - capabilities = capabilities, - - on_attach = function(client) - local lsp_config = vim.fs.find(function(name) - return name:match(".*%.delphilsp.json$") - end, { type = "file", path = client.config.root_dir, upward = false })[1] - - if lsp_config then - client.config.settings = { settingsFile = lsp_config } - client.notify("workspace/didChangeConfiguration", { settings = client.config.settings }) - else - vim.notify_once("delphi_ls: '*.delphilsp.json' config file not found") - end - end, - }) -end, -``` - -Snippet to enable the language server: >lua - require'lspconfig'.delphi_ls.setup{} - - -Default config: -- `cmd` : +- `root_markers` : ```lua - { "DelphiLSP.exe" } + { "debian" } ``` -- `filetypes` : - ```lua - { "pascal" } - ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/delphi_ls.lua:4](../lua/lspconfig/configs/delphi_ls.lua#L4) -- `single_file_support` : `false` ------------------------------------------------------------------------------ @@ -2461,12 +2202,9 @@ vim.g.markdown_fenced_languages = { ``` Snippet to enable the language server: >lua - require'lspconfig'.denols.setup{} + vim.lsp.enable('denols') -Commands: -- DenolsCache: Cache a module and all of its dependencies. - Default config: - `cmd` : ```lua @@ -2490,7 +2228,11 @@ Default config: ["textDocument/typeDefinition"] = <function 1> } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/denols.lua:66](../lua/lspconfig/configs/denols.lua#L66) +- `on_attach` source (use "gF" to open): [../lsp/denols.lua:78](../lsp/denols.lua#L78) +- `root_markers` : + ```lua + { "deno.json", "deno.jsonc", ".git" } + ``` - `settings` : ```lua { @@ -2522,7 +2264,7 @@ cabal install dhall-lsp-server prebuilt binaries can be found [here](https://github.com/dhall-lang/dhall-haskell/releases). Snippet to enable the language server: >lua - require'lspconfig'.dhall_lsp_server.setup{} + vim.lsp.enable('dhall_lsp_server') Default config: @@ -2534,8 +2276,10 @@ Default config: ```lua { "dhall" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/dhall_lsp_server.lua:2](../lua/lspconfig/configs/dhall_lsp_server.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -2546,7 +2290,7 @@ https://github.com/iamcco/diagnostic-languageserver Diagnostic language server integrate with linters. Snippet to enable the language server: >lua - require'lspconfig'.diagnosticls.setup{} + vim.lsp.enable('diagnosticls') Default config: @@ -2558,8 +2302,10 @@ Default config: ```lua {} ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/diagnosticls.lua:3](../lua/lspconfig/configs/diagnosticls.lua#L3) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -2574,7 +2320,7 @@ context-sensitive completion, documentation, code navigation, and related functi text editor that speaks the LSP protocol. Snippet to enable the language server: >lua - require'lspconfig'.digestif.setup{} + vim.lsp.enable('digestif') Default config: @@ -2586,8 +2332,10 @@ Default config: ```lua { "tex", "plaintex", "context" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/digestif.lua:2](../lua/lspconfig/configs/digestif.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -2595,10 +2343,8 @@ djlsp https://github.com/fourdigits/django-template-lsp - `djlsp`, a language server for Django templates. - Snippet to enable the language server: >lua - require'lspconfig'.djlsp.setup{} + vim.lsp.enable('djlsp') Default config: @@ -2610,7 +2356,10 @@ Default config: ```lua { "html", "htmldjango" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/djlsp.lua:2](../lua/lspconfig/configs/djlsp.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua {} @@ -2632,7 +2381,7 @@ npm install @microsoft/compose-language-service Note: If the docker-compose-langserver doesn't startup when entering a `docker-compose.yaml` file, make sure that the filetype is `yaml.docker-compose`. You can set with: `:set filetype=yaml.docker-compose`. Snippet to enable the language server: >lua - require'lspconfig'.docker_compose_language_service.setup{} + vim.lsp.enable('docker_compose_language_service') Default config: @@ -2644,8 +2393,10 @@ Default config: ```lua { "yaml.docker-compose" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/docker_compose_language_service.lua:4](../lua/lspconfig/configs/docker_compose_language_service.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "docker-compose.yaml", "docker-compose.yml", "compose.yaml", "compose.yml" } + ``` ------------------------------------------------------------------------------ @@ -2660,7 +2411,7 @@ npm install -g dockerfile-language-server-nodejs Additional configuration can be applied in the following way: ```lua -require("lspconfig").dockerls.setup { +vim.lsp.config('dockerls', { settings = { docker = { languageserver = { @@ -2670,11 +2421,11 @@ require("lspconfig").dockerls.setup { }, } } -} +}) ``` Snippet to enable the language server: >lua - require'lspconfig'.dockerls.setup{} + vim.lsp.enable('dockerls') Default config: @@ -2686,8 +2437,10 @@ Default config: ```lua { "dockerfile" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/dockerls.lua:4](../lua/lspconfig/configs/dockerls.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "Dockerfile" } + ``` ------------------------------------------------------------------------------ @@ -2701,7 +2454,7 @@ opam install dolmen_lsp ``` Snippet to enable the language server: >lua - require'lspconfig'.dolmenls.setup{} + vim.lsp.enable('dolmenls') Default config: @@ -2713,8 +2466,10 @@ Default config: ```lua { "smt2", "tptp", "p", "cnf", "icnf", "zf" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/dolmenls.lua:2](../lua/lspconfig/configs/dolmenls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -2728,7 +2483,7 @@ npm install -g dot-language-server ``` Snippet to enable the language server: >lua - require'lspconfig'.dotls.setup{} + vim.lsp.enable('dotls') Default config: @@ -2740,8 +2495,10 @@ Default config: ```lua { "dot" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/dotls.lua:2](../lua/lspconfig/configs/dotls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -2752,7 +2509,7 @@ https://github.com/dprint/dprint Pluggable and configurable code formatting platform written in Rust. Snippet to enable the language server: >lua - require'lspconfig'.dprint.setup{} + vim.lsp.enable('dprint') Default config: @@ -2764,61 +2521,14 @@ Default config: ```lua { "javascript", "javascriptreact", "typescript", "typescriptreact", "json", "jsonc", "markdown", "python", "toml", "rust", "roslyn", "graphql" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/dprint.lua:4](../lua/lspconfig/configs/dprint.lua#L4) -- `settings` : +- `root_markers` : ```lua - {} + { "dprint.json", ".dprint.json", "dprint.jsonc", ".dprint.jsonc" } ``` -- `single_file_support` : `true` - - ------------------------------------------------------------------------------- -drools_lsp - -https://github.com/kiegroup/drools-lsp - -Language server for the [Drools Rule Language (DRL)](https://docs.drools.org/latest/drools-docs/docs-website/drools/language-reference/#con-drl_drl-rules). - -The `drools-lsp` server is a self-contained java jar file (`drools-lsp-server-jar-with-dependencies.jar`), and can be downloaded from [https://github.com/kiegroup/drools-lsp/releases/](https://github.com/kiegroup/drools-lsp/releases/). - -Configuration information: -```lua --- Option 1) Specify the entire command: -require('lspconfig').drools_lsp.setup { - cmd = { '/path/to/java', '-jar', '/path/to/drools-lsp-server-jar-with-dependencies.jar' }, -} - --- Option 2) Specify just the jar path (the JAVA_HOME environment variable will be respected if present): -require('lspconfig').drools_lsp.setup { - drools = { jar = '/path/to/drools-lsp-server-jar-with-dependencies.jar' }, -} - --- Option 3) Specify the java bin and/or java opts in addition to the jar path: -require('lspconfig').drools_lsp.setup { - drools = { - java = { bin = '/path/to/java', opts = { '-Xmx100m' } }, - jar = '/path/to/drools-lsp-server-jar-with-dependencies.jar', - }, -} -``` - -Neovim does not yet have automatic detection for the `drools` filetype, but it can be added with: -```lua -vim.cmd [[ autocmd BufNewFile,BufRead *.drl set filetype=drools ]] -``` - -Snippet to enable the language server: >lua - require'lspconfig'.drools_lsp.setup{} - - -Default config: -- `filetypes` : +- `settings` : ```lua - { "drools" } + {} ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/drools_lsp.lua:36](../lua/lspconfig/configs/drools_lsp.lua#L36) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/drools_lsp.lua:36](../lua/lspconfig/configs/drools_lsp.lua#L36) -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -2831,22 +2541,18 @@ And make ensure the database file `dict.db3` is also downloaded. And put the pat ```lua -require('lspconfig').ds_pinyin_lsp.setup { +vim.lsp.config('ds_pinyin_lsp', { init_options = { db_path = "your_path_to_database" } -} +}) ``` Snippet to enable the language server: >lua - require'lspconfig'.ds_pinyin_lsp.setup{} + vim.lsp.enable('ds_pinyin_lsp') -Commands: -- DsPinyinCompletionOff: Turn off the ds-pinyin-lsp completion -- DsPinyinCompletionOn: Turn on the ds-pinyin-lsp completion - Default config: - `cmd` : ```lua @@ -2868,8 +2574,11 @@ Default config: show_symbols_only_follow_by_hanzi = false } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ds_pinyin_lsp.lua:33](../lua/lspconfig/configs/ds_pinyin_lsp.lua#L33) -- `single_file_support` : `true` +- `on_attach` source (use "gF" to open): [../lsp/ds_pinyin_lsp.lua:48](../lsp/ds_pinyin_lsp.lua#L48) +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -2888,7 +2597,7 @@ https://www.devicetree.org/ https://docs.zephyrproject.org/latest/build/dts/index.html Snippet to enable the language server: >lua - require'lspconfig'.dts_lsp.setup{} + vim.lsp.enable('dts_lsp') Default config: @@ -2904,7 +2613,10 @@ Default config: ```lua "dts_lsp" ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/dts_lsp.lua:2](../lua/lspconfig/configs/dts_lsp.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua {} @@ -2919,7 +2631,7 @@ https://github.com/glehmann/earthlyls A fast language server for earthly. Snippet to enable the language server: >lua - require'lspconfig'.earthlyls.setup{} + vim.lsp.enable('earthlyls') Default config: @@ -2931,7 +2643,10 @@ Default config: ```lua { "earthfile" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/earthlyls.lua:4](../lua/lspconfig/configs/earthlyls.lua#L4) +- `root_markers` : + ```lua + { "Earthfile" } + ``` ------------------------------------------------------------------------------ @@ -2945,7 +2660,7 @@ The default cmd assumes `ecsact_lsp_server` is in your PATH. Typically from the Ecsact SDK: https://ecsact.dev/start Snippet to enable the language server: >lua - require'lspconfig'.ecsact.setup{} + vim.lsp.enable('ecsact') Default config: @@ -2957,50 +2672,10 @@ Default config: ```lua { "ecsact" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ecsact.lua:4](../lua/lspconfig/configs/ecsact.lua#L4) -- `single_file_support` : `true` - - ------------------------------------------------------------------------------- -efm - -https://github.com/mattn/efm-langserver - -General purpose Language Server that can use specified error message format generated from specified command. - -Requires at minimum EFM version [v0.0.38](https://github.com/mattn/efm-langserver/releases/tag/v0.0.38) to support -launching the language server on single files. If on an older version of EFM, disable single file support: - -```lua -require('lspconfig')['efm'].setup{ - settings = ..., -- You must populate this according to the EFM readme - filetypes = ..., -- Populate this according to the note below - single_file_support = false, -- This is the important line for supporting older version of EFM -} -``` - -Note: In order for neovim's built-in language server client to send the appropriate `languageId` to EFM, **you must -specify `filetypes` in your call to `setup{}`**. Otherwise `lspconfig` will launch EFM on the `BufEnter` instead -of the `FileType` autocommand, and the `filetype` variable used to populate the `languageId` will not yet be set. - -```lua -require('lspconfig')['efm'].setup{ - settings = ..., -- You must populate this according to the EFM readme - filetypes = { 'python','cpp','lua' } -} -``` - -Snippet to enable the language server: >lua - require'lspconfig'.efm.setup{} - - -Default config: -- `cmd` : +- `root_markers` : ```lua - { "efm-langserver" } + { ".git" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/efm.lua:2](../lua/lspconfig/configs/efm.lua#L2) -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -3021,19 +2696,19 @@ https://github.com/elixir-lsp/elixir-ls **By default, elixir-ls doesn't have a `cmd` set.** This is because nvim-lspconfig does not make assumptions about your path. You must add the following to your init.vim or init.lua to set `cmd` to the absolute path ($HOME and ~ are not expanded) of your unzipped elixir-ls. ```lua -require'lspconfig'.elixirls.setup{ +vim.lsp.config('elixirls', { -- Unix cmd = { "/path/to/elixir-ls/language_server.sh" }; -- Windows cmd = { "/path/to/elixir-ls/language_server.bat" }; ... -} +}) ``` 'root_dir' is chosen like this: if two or more directories containing `mix.exs` were found when searching directories upward, the second one (higher up) is chosen, with the assumption that it is the root of an umbrella app. Otherwise the directory containing the single mix.exs that was found is chosen. Snippet to enable the language server: >lua - require'lspconfig'.elixirls.setup{} + vim.lsp.enable('elixirls') Default config: @@ -3041,8 +2716,7 @@ Default config: ```lua { "elixir", "eelixir", "heex", "surface" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/elixirls.lua:2](../lua/lspconfig/configs/elixirls.lua#L2) -- `single_file_support` : `true` +- `root_dir` source (use "gF" to open): [../lsp/elixirls.lua:28](../lsp/elixirls.lua#L28) ------------------------------------------------------------------------------ @@ -3056,7 +2730,7 @@ npm install -g elm elm-test elm-format @elm-tooling/elm-language-server ``` Snippet to enable the language server: >lua - require'lspconfig'.elmls.setup{} + vim.lsp.enable('elmls') Default config: @@ -3083,7 +2757,7 @@ Default config: skipInstallPackageConfirmation = false } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/elmls.lua:7](../lua/lspconfig/configs/elmls.lua#L7) +- `root_dir` source (use "gF" to open): [../lsp/elmls.lua:14](../lsp/elmls.lua#L14) ------------------------------------------------------------------------------ @@ -3095,7 +2769,7 @@ ELP integrates Erlang into modern IDEs via the language server protocol and was inspired by rust-analyzer. Snippet to enable the language server: >lua - require'lspconfig'.elp.setup{} + vim.lsp.enable('elp') Default config: @@ -3107,8 +2781,10 @@ Default config: ```lua { "erlang" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/elp.lua:4](../lua/lspconfig/configs/elp.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "rebar.config", "erlang.mk", ".git" } + ``` ------------------------------------------------------------------------------ @@ -3123,7 +2799,7 @@ npm install -g @ember-tooling/ember-language-server ``` Snippet to enable the language server: >lua - require'lspconfig'.ember.setup{} + vim.lsp.enable('ember') Default config: @@ -3135,7 +2811,10 @@ Default config: ```lua { "handlebars", "typescript", "javascript", "typescript.glimmer", "javascript.glimmer" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ember.lua:4](../lua/lspconfig/configs/ember.lua#L4) +- `root_markers` : + ```lua + { "ember-cli-build.js", ".git" } + ``` ------------------------------------------------------------------------------ @@ -3149,7 +2828,7 @@ npm install -g @olrtg/emmet-language-server ``` Snippet to enable the language server: >lua - require'lspconfig'.emmet_language_server.setup{} + vim.lsp.enable('emmet_language_server') Default config: @@ -3161,8 +2840,10 @@ Default config: ```lua { "css", "eruby", "html", "htmldjango", "javascriptreact", "less", "pug", "sass", "scss", "typescriptreact", "htmlangular" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/emmet_language_server.lua:2](../lua/lspconfig/configs/emmet_language_server.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -3176,7 +2857,7 @@ npm install -g emmet-ls ``` Snippet to enable the language server: >lua - require'lspconfig'.emmet_ls.setup{} + vim.lsp.enable('emmet_ls') Default config: @@ -3188,8 +2869,10 @@ Default config: ```lua { "astro", "css", "eruby", "html", "htmldjango", "javascriptreact", "less", "pug", "sass", "scss", "svelte", "typescriptreact", "vue", "htmlangular" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/emmet_ls.lua:2](../lua/lspconfig/configs/emmet_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -3206,7 +2889,7 @@ erg-language-server can be installed via `cargo` and used as follows: ``` Snippet to enable the language server: >lua - require'lspconfig'.erg_language_server.setup{} + vim.lsp.enable('erg_language_server') Default config: @@ -3218,7 +2901,10 @@ Default config: ```lua { "erg" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/erg_language_server.lua:4](../lua/lspconfig/configs/erg_language_server.lua#L4) +- `root_markers` : + ```lua + { "package.er", ".git" } + ``` ------------------------------------------------------------------------------ @@ -3238,7 +2924,7 @@ Installation requirements: - [rebar3 3.9.1+](https://github.com/erlang/rebar3) Snippet to enable the language server: >lua - require'lspconfig'.erlangls.setup{} + vim.lsp.enable('erlangls') Default config: @@ -3250,8 +2936,10 @@ Default config: ```lua { "erlang" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/erlangls.lua:4](../lua/lspconfig/configs/erlangls.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "rebar.config", "erlang.mk", ".git" } + ``` ------------------------------------------------------------------------------ @@ -3278,15 +2966,15 @@ nvim Or you can modify the default `cmd` to include the full path to the Python interpreter. ```lua -require'lspconfig'.esbonio.setup { +vim.lsp.config('esbonio', { cmd = { '/path/to/virtualenv/bin/python', '-m', 'esbonio' } -} +}) ``` Esbonio supports a number of config values passed as `init_options` on startup, for example. ```lua -require'lspconfig'.esbonio.setup { +vim.lsp.config('esbonio', { init_options = { server = { logLevel = "debug" @@ -3295,13 +2983,13 @@ require'lspconfig'.esbonio.setup { confDir = "/path/to/docs", srcDir = "${confDir}/../docs-src" } -} +}) ``` A full list and explanation of the available options can be found [here](https://docs.esbon.io/en/esbonio-language-server-v0.16.4/lsp/getting-started.html?editor=neovim-lspconfig#configuration) Snippet to enable the language server: >lua - require'lspconfig'.esbonio.setup{} + vim.lsp.enable('esbonio') Default config: @@ -3313,101 +3001,9 @@ Default config: ```lua { "rst" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/esbonio.lua:2](../lua/lspconfig/configs/esbonio.lua#L2) - - ------------------------------------------------------------------------------- -eslint - -https://github.com/hrsh7th/vscode-langservers-extracted - -`vscode-eslint-language-server` is a linting engine for JavaScript / Typescript. -It can be installed via `npm`: - -```sh -npm i -g vscode-langservers-extracted -``` - -`vscode-eslint-language-server` provides an `EslintFixAll` command that can be used to format a document on save: -```lua -lspconfig.eslint.setup({ - --- ... - on_attach = function(client, bufnr) - vim.api.nvim_create_autocmd("BufWritePre", { - buffer = bufnr, - command = "EslintFixAll", - }) - end, -}) -``` - -See [vscode-eslint](https://github.com/microsoft/vscode-eslint/blob/55871979d7af184bf09af491b6ea35ebd56822cf/server/src/eslintServer.ts#L216-L229) for configuration options. - -Messages handled in lspconfig: `eslint/openDoc`, `eslint/confirmESLintExecution`, `eslint/probeFailed`, `eslint/noLibrary` - -Additional messages you can handle: `eslint/noConfig` - -Snippet to enable the language server: >lua - require'lspconfig'.eslint.setup{} - - -Commands: -- EslintFixAll: Fix all eslint problems for this buffer - -Default config: -- `cmd` : +- `root_markers` : ```lua - { "vscode-eslint-language-server", "--stdio" } - ``` -- `filetypes` : - ```lua - { "javascript", "javascriptreact", "javascript.jsx", "typescript", "typescriptreact", "typescript.tsx", "vue", "svelte", "astro" } - ``` -- `handlers` : - ```lua - { - ["eslint/confirmESLintExecution"] = <function 1>, - ["eslint/noLibrary"] = <function 2>, - ["eslint/openDoc"] = <function 3>, - ["eslint/probeFailed"] = <function 4> - } - ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/eslint.lua:51](../lua/lspconfig/configs/eslint.lua#L51) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/eslint.lua:51](../lua/lspconfig/configs/eslint.lua#L51) -- `settings` : - ```lua - { - codeAction = { - disableRuleComment = { - enable = true, - location = "separateLine" - }, - showDocumentation = { - enable = true - } - }, - codeActionOnSave = { - enable = false, - mode = "all" - }, - experimental = { - useFlatConfig = false - }, - format = true, - nodePath = "", - onIgnoredFiles = "off", - problems = { - shortenToSingleLine = false - }, - quiet = false, - rulesCustomizations = {}, - run = "onType", - useESLintClass = false, - validate = "on", - workingDirectory = { - mode = "location" - } - } + { ".git" } ``` @@ -3419,7 +3015,7 @@ https://github.com/FacilityApi/FacilityLanguageServer Facility language server protocol (LSP) support. Snippet to enable the language server: >lua - require'lspconfig'.facility_language_server.setup{} + vim.lsp.enable('facility_language_server') Default config: @@ -3431,8 +3027,10 @@ Default config: ```lua { "fsd" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/facility_language_server.lua:2](../lua/lspconfig/configs/facility_language_server.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -3443,7 +3041,7 @@ https://github.com/rydesun/fennel-language-server Fennel language server protocol (LSP) support. Snippet to enable the language server: >lua - require'lspconfig'.fennel_language_server.setup{} + vim.lsp.enable('fennel_language_server') Default config: @@ -3455,12 +3053,14 @@ Default config: ```lua { "fennel" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/fennel_language_server.lua:2](../lua/lspconfig/configs/fennel_language_server.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua {} ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -3474,7 +3074,7 @@ fennel-ls is configured using the closest file to your working directory named ` All fennel-ls configuration options [can be found here](https://git.sr.ht/~xerool/fennel-ls/tree/HEAD/docs/manual.md#configuration). Snippet to enable the language server: >lua - require'lspconfig'.fennel_ls.setup{} + vim.lsp.enable('fennel_ls') Default config: @@ -3492,12 +3092,11 @@ Default config: ```lua { "fennel" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/fennel_ls.lua:4](../lua/lspconfig/configs/fennel_ls.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/fennel_ls.lua:11](../lsp/fennel_ls.lua#L11) - `settings` : ```lua {} ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -3513,7 +3112,7 @@ scope aware symbol analysis, per-token hover generation, and many others. [homepage](https://www.fish-lsp.dev/) Snippet to enable the language server: >lua - require'lspconfig'.fish_lsp.setup{} + vim.lsp.enable('fish_lsp') Default config: @@ -3531,8 +3130,10 @@ Default config: ```lua { "fish" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/fish_lsp.lua:2](../lua/lspconfig/configs/fish_lsp.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -3551,7 +3152,7 @@ npx flow lsp --help ``` Snippet to enable the language server: >lua - require'lspconfig'.flow.setup{} + vim.lsp.enable('flow') Default config: @@ -3563,7 +3164,10 @@ Default config: ```lua { "javascript", "javascriptreact", "javascript.jsx" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/flow.lua:4](../lua/lspconfig/configs/flow.lua#L4) +- `root_markers` : + ```lua + { ".flowconfig" } + ``` ------------------------------------------------------------------------------ @@ -3576,7 +3180,7 @@ cargo install --git https://github.com/influxdata/flux-lsp ``` Snippet to enable the language server: >lua - require'lspconfig'.flux_lsp.setup{} + vim.lsp.enable('flux_lsp') Default config: @@ -3588,8 +3192,10 @@ Default config: ```lua { "flux" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/flux_lsp.lua:2](../lua/lspconfig/configs/flux_lsp.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -3603,7 +3209,7 @@ npm install -g foam-language-server ``` Snippet to enable the language server: >lua - require'lspconfig'.foam_ls.setup{} + vim.lsp.enable('foam_ls') Default config: @@ -3615,7 +3221,7 @@ Default config: ```lua { "foam", "OpenFOAM" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/foam_ls.lua:4](../lua/lspconfig/configs/foam_ls.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/foam_ls.lua:11](../lsp/foam_ls.lua#L11) ------------------------------------------------------------------------------ @@ -3634,7 +3240,7 @@ a local configuration file e.g. `.fortls`. For more information see the `fortls` [documentation](https://fortls.fortran-lang.org/options.html). Snippet to enable the language server: >lua - require'lspconfig'.fortls.setup{} + vim.lsp.enable('fortls') Default config: @@ -3646,7 +3252,10 @@ Default config: ```lua { "fortran" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/fortls.lua:4](../lua/lspconfig/configs/fortls.lua#L4) +- `root_markers` : + ```lua + { ".fortls", ".git" } + ``` - `settings` : ```lua {} @@ -3673,7 +3282,7 @@ You may also need to configure the filetype as Vim defaults to Forth for `*.fs` This is automatically done by plugins such as [PhilT/vim-fsharp](https://github.com/PhilT/vim-fsharp), [fsharp/vim-fsharp](https://github.com/fsharp/vim-fsharp), and [adelarsq/neofsharp.vim](https://github.com/adelarsq/neofsharp.vim). Snippet to enable the language server: >lua - require'lspconfig'.fsautocomplete.setup{} + vim.lsp.enable('fsautocomplete') Default config: @@ -3691,7 +3300,7 @@ Default config: AutomaticWorkspaceInit = true } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/fsautocomplete.lua:4](../lua/lspconfig/configs/fsautocomplete.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/fsautocomplete.lua:21](../lsp/fsautocomplete.lua#L21) - `settings` : ```lua { @@ -3734,7 +3343,7 @@ If filetype determination is not already performed by an available plugin ([Phil `autocmd BufNewFile,BufRead *.fs,*.fsx,*.fsi set filetype=fsharp` Snippet to enable the language server: >lua - require'lspconfig'.fsharp_language_server.setup{} + vim.lsp.enable('fsharp_language_server') Default config: @@ -3752,7 +3361,7 @@ Default config: AutomaticWorkspaceInit = true } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/fsharp_language_server.lua:4](../lua/lspconfig/configs/fsharp_language_server.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/fsharp_language_server.lua:17](../lsp/fsharp_language_server.lua#L17) - `settings` : ```lua {} @@ -3767,7 +3376,7 @@ https://github.com/FStarLang/FStar LSP support is included in FStar. Make sure `fstar.exe` is in your PATH. Snippet to enable the language server: >lua - require'lspconfig'.fstar.setup{} + vim.lsp.enable('fstar') Default config: @@ -3779,7 +3388,10 @@ Default config: ```lua { "fstar" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/fstar.lua:2](../lua/lspconfig/configs/fstar.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -3795,7 +3407,7 @@ futhark lsp ``` Snippet to enable the language server: >lua - require'lspconfig'.futhark_lsp.setup{} + vim.lsp.enable('futhark_lsp') Default config: @@ -3807,8 +3419,10 @@ Default config: ```lua { "futhark", "fut" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/futhark_lsp.lua:2](../lua/lspconfig/configs/futhark_lsp.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -3819,16 +3433,19 @@ https://github.com/godotengine/godot Language server for GDScript, used by Godot Engine. Snippet to enable the language server: >lua - require'lspconfig'.gdscript.setup{} + vim.lsp.enable('gdscript') Default config: -- `cmd` source (use "gF" to visit): [../lua/lspconfig/configs/gdscript.lua:7](../lua/lspconfig/configs/gdscript.lua#L7) +- `cmd` source (use "gF" to open): [../lsp/gdscript.lua:9](../lsp/gdscript.lua#L9) - `filetypes` : ```lua { "gd", "gdscript", "gdscript3" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/gdscript.lua:7](../lua/lspconfig/configs/gdscript.lua#L7) +- `root_markers` : + ```lua + { "project.godot", ".git" } + ``` ------------------------------------------------------------------------------ @@ -3839,7 +3456,7 @@ https://github.com/godofavacyn/gdshader-lsp A language server for the Godot Shading language. Snippet to enable the language server: >lua - require'lspconfig'.gdshader_lsp.setup{} + vim.lsp.enable('gdshader_lsp') Default config: @@ -3851,52 +3468,10 @@ Default config: ```lua { "gdshader", "gdshaderinc" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/gdshader_lsp.lua:4](../lua/lspconfig/configs/gdshader_lsp.lua#L4) - - ------------------------------------------------------------------------------- -gh_actions_ls - -https://github.com/lttb/gh-actions-language-server - -Language server for GitHub Actions. - -The projects [forgejo](https://forgejo.org/) and [gitea](https://about.gitea.com/) -design their actions to be as compatible to github as possible -with only [a few differences](https://docs.gitea.com/usage/actions/comparison#unsupported-workflows-syntax) between the systems. -The `gh_actions_ls` is therefore enabled for those `yaml` files as well. - -The `gh-actions-language-server` can be installed via `npm`: - -```sh -npm install -g gh-actions-language-server -``` - -Snippet to enable the language server: >lua - require'lspconfig'.gh_actions_ls.setup{} - - -Default config: -- `capabilities` : +- `root_markers` : ```lua - { - workspace = { - didChangeWorkspaceFolders = { - dynamicRegistration = true - } - } - } + { "project.godot" } ``` -- `cmd` : - ```lua - { "gh-actions-language-server", "--stdio" } - ``` -- `filetypes` : - ```lua - { "yaml" } - ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/gh_actions_ls.lua:2](../lua/lspconfig/configs/gh_actions_ls.lua#L2) -- `single_file_support` : `false` ------------------------------------------------------------------------------ @@ -3908,7 +3483,7 @@ A library for building Haskell IDE tooling. "ghcide" isn't for end users now. Use "haskell-language-server" instead of "ghcide". Snippet to enable the language server: >lua - require'lspconfig'.ghcide.setup{} + vim.lsp.enable('ghcide') Default config: @@ -3920,7 +3495,10 @@ Default config: ```lua { "haskell", "lhaskell" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ghcide.lua:4](../lua/lspconfig/configs/ghcide.lua#L4) +- `root_markers` : + ```lua + { "stack.yaml", "hie-bios", "BUILD.bazel", "cabal.config", "package.yaml" } + ``` ------------------------------------------------------------------------------ @@ -3934,7 +3512,7 @@ A language server for VHDL, using ghdl as its backend. [the upstream README](https://github.com/ghdl/ghdl/tree/master/pyGHDL/lsp). Snippet to enable the language server: >lua - require'lspconfig'.ghdl_ls.setup{} + vim.lsp.enable('ghdl_ls') Default config: @@ -3946,23 +3524,25 @@ Default config: ```lua { "vhdl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ghdl_ls.lua:4](../lua/lspconfig/configs/ghdl_ls.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "hdl-prj.json", ".git" } + ``` ------------------------------------------------------------------------------ ginko_ls `ginko_ls` is meant to be a feature-complete language server for device-trees. -Language servers can be used in many editors, such as Visual Studio Code, Emacs -or Vim + Language servers can be used in many editors, such as Visual Studio Code, Emacs + or Vim -Install `ginko_ls` from https://github.com/Schottkyc137/ginko and add it to path + Install `ginko_ls` from https://github.com/Schottkyc137/ginko and add it to path -`ginko_ls` doesn't require any configuration. + `ginko_ls` doesn't require any configuration. Snippet to enable the language server: >lua - require'lspconfig'.ginko_ls.setup{} + vim.lsp.enable('ginko_ls') Default config: @@ -3974,7 +3554,10 @@ Default config: ```lua { "dts" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ginko_ls.lua:2](../lua/lspconfig/configs/ginko_ls.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua {} @@ -3992,7 +3575,7 @@ Language Server for Gitlab CI cargo install gitlab-ci-ls Snippet to enable the language server: >lua - require'lspconfig'.gitlab_ci_ls.setup{} + vim.lsp.enable('gitlab_ci_ls') Default config: @@ -4007,11 +3590,11 @@ Default config: - `init_options` : ```lua { - cache_path = "/home/user/.cache/gitlab-ci-ls/", - log_path = "/home/user/.cache/gitlab-ci-ls//log/gitlab-ci-ls.log" + cache_path = ".//.cache/gitlab-ci-ls/", + log_path = ".//.cache/gitlab-ci-ls//log/gitlab-ci-ls.log" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/gitlab_ci_ls.lua:5](../lua/lspconfig/configs/gitlab_ci_ls.lua#L5) +- `root_dir` source (use "gF" to open): [../lsp/gitlab_ci_ls.lua:13](../lsp/gitlab_ci_ls.lua#L13) ------------------------------------------------------------------------------ @@ -4039,7 +3622,7 @@ cargo install glasgow ``` Snippet to enable the language server: >lua - require'lspconfig'.glasgow.setup{} + vim.lsp.enable('glasgow') Default config: @@ -4051,12 +3634,14 @@ Default config: ```lua { "wgsl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/glasgow.lua:2](../lua/lspconfig/configs/glasgow.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua {} ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -4069,7 +3654,7 @@ A language server for Gleam Programming Language. It comes with the Gleam compiler, for installation see: [Installing Gleam](https://gleam.run/getting-started/installing/) Snippet to enable the language server: >lua - require'lspconfig'.gleam.setup{} + vim.lsp.enable('gleam') Default config: @@ -4081,49 +3666,10 @@ Default config: ```lua { "gleam" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/gleam.lua:4](../lua/lspconfig/configs/gleam.lua#L4) - - ------------------------------------------------------------------------------- -glint - -https://github.com/typed-ember/glint - - https://typed-ember.gitbook.io/glint/ - - `glint-language-server` is installed when adding `@glint/core` to your project's devDependencies: - - ```sh - npm install @glint/core --save-dev - ``` - - or - - ```sh - yarn add -D @glint/core - ``` - - or - - ```sh - pnpm add -D @glint/core - ``` - -Snippet to enable the language server: >lua - require'lspconfig'.glint.setup{} - - -Default config: -- `cmd` : +- `root_markers` : ```lua - { "glint-language-server" } + { "gleam.toml", ".git" } ``` -- `filetypes` : - ```lua - { "html.handlebars", "handlebars", "typescript", "typescript.glimmer", "javascript", "javascript.glimmer" } - ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/glint.lua:4](../lua/lspconfig/configs/glint.lua#L4) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/glint.lua:4](../lua/lspconfig/configs/glint.lua#L4) ------------------------------------------------------------------------------ @@ -4134,7 +3680,7 @@ https://github.com/nolanderc/glsl_analyzer Language server for GLSL Snippet to enable the language server: >lua - require'lspconfig'.glsl_analyzer.setup{} + vim.lsp.enable('glsl_analyzer') Default config: @@ -4150,8 +3696,10 @@ Default config: ```lua { "glsl", "vert", "tesc", "tese", "frag", "geom", "comp" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/glsl_analyzer.lua:2](../lua/lspconfig/configs/glsl_analyzer.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -4165,7 +3713,7 @@ Language server implementation for GLSL via the `glsl-language-server` AUR package Snippet to enable the language server: >lua - require'lspconfig'.glslls.setup{} + vim.lsp.enable('glslls') Default config: @@ -4188,8 +3736,10 @@ Default config: ```lua { "glsl", "vert", "tesc", "tese", "frag", "geom", "comp" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/glslls.lua:2](../lua/lspconfig/configs/glslls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -4197,19 +3747,19 @@ golangci_lint_ls Combination of both lint server and client -https://github.com/nametake/golangci-lint-langserver -https://github.com/golangci/golangci-lint + https://github.com/nametake/golangci-lint-langserver + https://github.com/golangci/golangci-lint -Installation of binaries needed is done via + Installation of binaries needed is done via -``` -go install github.com/nametake/golangci-lint-langserver@latest -go install github.com/golangci/golangci-lint/cmd/golangci-lint@latest -``` + ``` + go install github.com/nametake/golangci-lint-langserver@latest + go install github.com/golangci/golangci-lint/cmd/golangci-lint@latest + ``` Snippet to enable the language server: >lua - require'lspconfig'.golangci_lint_ls.setup{} + vim.lsp.enable('golangci_lint_ls') Default config: @@ -4227,7 +3777,10 @@ Default config: command = { "golangci-lint", "run", "--output.json.path=stdout", "--show-stats=false" } } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/golangci_lint_ls.lua:4](../lua/lspconfig/configs/golangci_lint_ls.lua#L4) +- `root_markers` : + ```lua + { ".golangci.yml", ".golangci.yaml", ".golangci.toml", ".golangci.json", "go.work", "go.mod", ".git" } + ``` ------------------------------------------------------------------------------ @@ -4238,7 +3791,7 @@ https://github.com/golang/tools/tree/master/gopls Google's lsp server for golang. Snippet to enable the language server: >lua - require'lspconfig'.gopls.setup{} + vim.lsp.enable('gopls') Default config: @@ -4250,8 +3803,7 @@ Default config: ```lua { "go", "gomod", "gowork", "gotmpl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/gopls.lua:6](../lua/lspconfig/configs/gopls.lua#L6) -- `single_file_support` : `true` +- `root_dir` source (use "gF" to open): [../lsp/gopls.lua:20](../lsp/gopls.lua#L20) ------------------------------------------------------------------------------ @@ -4264,7 +3816,7 @@ Microsoft's lsp server for gradle files If you're setting this up manually, build vscode-gradle using `./gradlew installDist` and point `cmd` to the `gradle-language-server` generated in the build directory Snippet to enable the language server: >lua - require'lspconfig'.gradle_ls.setup{} + vim.lsp.enable('gradle_ls') Default config: @@ -4284,7 +3836,10 @@ Default config: } } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/gradle_ls.lua:9](../lua/lspconfig/configs/gradle_ls.lua#L9) +- `root_markers` : + ```lua + { "settings.gradle", "build.gradle" } + ``` ------------------------------------------------------------------------------ @@ -4301,7 +3856,7 @@ npm i -g grammarly-languageserver WARNING: Since this language server uses Grammarly's API, any document you open with it running is shared with them. Please evaluate their [privacy policy](https://www.grammarly.com/privacy-policy) before using this. Snippet to enable the language server: >lua - require'lspconfig'.grammarly.setup{} + vim.lsp.enable('grammarly') Default config: @@ -4325,8 +3880,10 @@ Default config: clientId = "client_BaDkMgx4X19X9UxxYRCXZo" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/grammarly.lua:2](../lua/lspconfig/configs/grammarly.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -4343,7 +3900,7 @@ npm install -g graphql-language-service-cli Note that you must also have [the graphql package](https://github.com/graphql/graphql-js) installed within your project and create a [GraphQL config file](https://the-guild.dev/graphql/config/docs). Snippet to enable the language server: >lua - require'lspconfig'.graphql.setup{} + vim.lsp.enable('graphql') Default config: @@ -4355,7 +3912,7 @@ Default config: ```lua { "graphql", "typescriptreact", "javascriptreact" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/graphql.lua:4](../lua/lspconfig/configs/graphql.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/graphql.lua:14](../lsp/graphql.lua#L14) ------------------------------------------------------------------------------ @@ -4372,15 +3929,15 @@ Requirements: If you have installed groovy language server, you can set the `cmd` custom path as follow: ```lua -require'lspconfig'.groovyls.setup{ +vim.lsp.config('groovyls', { -- Unix cmd = { "java", "-jar", "path/to/groovyls/groovy-language-server-all.jar" }, ... -} +}) ``` Snippet to enable the language server: >lua - require'lspconfig'.groovyls.setup{} + vim.lsp.enable('groovyls') Default config: @@ -4392,7 +3949,10 @@ Default config: ```lua { "groovy" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/groovyls.lua:4](../lua/lspconfig/configs/groovyls.lua#L4) +- `root_markers` : + ```lua + { "Jenkinsfile", ".git" } + ``` ------------------------------------------------------------------------------ @@ -4410,7 +3970,7 @@ Checkout the repo for more info. Note: This LSP will start on `scheme.guile` filetype. You can set this file type using `:help modeline` or adding https://gitlab.com/HiPhish/guile.vim to your plugins to automatically set it. Snippet to enable the language server: >lua - require'lspconfig'.guile_ls.setup{} + vim.lsp.enable('guile_ls') Default config: @@ -4422,8 +3982,10 @@ Default config: ```lua { "scheme.guile" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/guile_ls.lua:3](../lua/lspconfig/configs/guile_ls.lua#L3) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "guix.scm", ".git" } + ``` ------------------------------------------------------------------------------ @@ -4437,17 +3999,17 @@ See our [documentation](https://writewithharper.com/docs/integrations/neovim) fo In short, they should look something like this: ```lua -lspconfig.harper_ls.setup { +vim.lsp.config('harper_ls', { settings = { ["harper-ls"] = { userDictPath = "~/dict.txt" } }, -} +}) ``` Snippet to enable the language server: >lua - require'lspconfig'.harper_ls.setup{} + vim.lsp.enable('harper_ls') Default config: @@ -4459,73 +4021,9 @@ Default config: ```lua { "c", "cpp", "cs", "gitcommit", "go", "html", "java", "javascript", "lua", "markdown", "nix", "python", "ruby", "rust", "swift", "toml", "typescript", "typescriptreact", "haskell", "cmake", "typst", "php", "dart" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/harper_ls.lua:2](../lua/lspconfig/configs/harper_ls.lua#L2) -- `single_file_support` : `true` - - ------------------------------------------------------------------------------- -haxe_language_server - -https://github.com/vshaxe/haxe-language-server - -The Haxe language server can be built by running the following commands from -the project's root directory: - - npm install - npx lix run vshaxe-build -t language-server - -This will create `bin/server.js`. Note that the server requires Haxe 3.4.0 or -higher. - -After building the language server, set the `cmd` setting in your setup -function: - -```lua -lspconfig.haxe_language_server.setup({ - cmd = {"node", "path/to/bin/server.js"}, -}) -``` - -By default, the language server is configured with the HXML compiler arguments -contained in the first `.hxml` file found in your project's root directory. -If you want to specify which one to use, set the `init_options.displayArguments` -setting: - -```lua -lspconfig.haxe_language_server.setup({ - -- ... - init_options = { - displayArguments = { "build.hxml" }, - }, -}) -``` - -Snippet to enable the language server: >lua - require'lspconfig'.haxe_language_server.setup{} - - -Default config: -- `cmd` : - ```lua - { "haxe-language-server" } - ``` -- `filetypes` : - ```lua - { "haxe" } - ``` -- `init_options` : - ```lua - {} - ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/haxe_language_server.lua:10](../lua/lspconfig/configs/haxe_language_server.lua#L10) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/haxe_language_server.lua:10](../lua/lspconfig/configs/haxe_language_server.lua#L10) -- `settings` : +- `root_markers` : ```lua - { - haxe = { - executable = "haxe" - } - } + { ".git" } ``` @@ -4537,7 +4035,7 @@ Language server for hdl-checker. Install using: `pip install hdl-checker --upgrade` Snippet to enable the language server: >lua - require'lspconfig'.hdl_checker.setup{} + vim.lsp.enable('hdl_checker') Default config: @@ -4549,8 +4047,10 @@ Default config: ```lua { "vhdl", "verilog", "systemverilog" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/hdl_checker.lua:2](../lua/lspconfig/configs/hdl_checker.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -4567,7 +4067,7 @@ The default `cmd` assumes that the `helm_ls` binary can be found in `$PATH`. If need Helm file highlight use [vim-helm](https://github.com/towolf/vim-helm) plugin. Snippet to enable the language server: >lua - require'lspconfig'.helm_ls.setup{} + vim.lsp.enable('helm_ls') Default config: @@ -4589,21 +4089,23 @@ Default config: ```lua { "helm" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/helm_ls.lua:4](../lua/lspconfig/configs/helm_ls.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "Chart.yaml" } + ``` ------------------------------------------------------------------------------ hhvm Language server for programs written in Hack -https://hhvm.com/ -https://github.com/facebook/hhvm -See below for how to setup HHVM & typechecker: -https://docs.hhvm.com/hhvm/getting-started/getting-started + https://hhvm.com/ + https://github.com/facebook/hhvm + See below for how to setup HHVM & typechecker: + https://docs.hhvm.com/hhvm/getting-started/getting-started Snippet to enable the language server: >lua - require'lspconfig'.hhvm.setup{} + vim.lsp.enable('hhvm') Default config: @@ -4615,7 +4117,10 @@ Default config: ```lua { "php", "hack" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/hhvm.lua:4](../lua/lspconfig/configs/hhvm.lua#L4) +- `root_markers` : + ```lua + { ".hhconfig" } + ``` ------------------------------------------------------------------------------ @@ -4639,7 +4144,7 @@ init_options = { ``` Snippet to enable the language server: >lua - require'lspconfig'.hie.setup{} + vim.lsp.enable('hie') Default config: @@ -4651,7 +4156,10 @@ Default config: ```lua { "haskell" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/hie.lua:4](../lua/lspconfig/configs/hie.lua#L4) +- `root_markers` : + ```lua + { "stack.yaml", "package.yaml", ".git" } + ``` ------------------------------------------------------------------------------ @@ -4659,10 +4167,10 @@ hlasm `hlasm_language_server` is a language server for the High Level Assembler language used on IBM SystemZ mainframes. - To learn how to configure the HLASM language server, see the [HLASM Language Support documentation](https://github.com/eclipse-che4z/che-che4z-lsp-for-hlasm). + To learn how to configure the HLASM language server, see the [HLASM Language Support documentation](https://github.com/eclipse-che4z/che-che4z-lsp-for-hlasm). Snippet to enable the language server: >lua - require'lspconfig'.hlasm.setup{} + vim.lsp.enable('hlasm') Default config: @@ -4674,8 +4182,10 @@ Default config: ```lua { "hlasm" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/hlasm.lua:4](../lua/lspconfig/configs/hlasm.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".hlasmplugin" } + ``` ------------------------------------------------------------------------------ @@ -4688,13 +4198,13 @@ Haskell Language Server If you are using HLS 1.9.0.0, enable the language server to launch on Cabal files as well: ```lua -require('lspconfig')['hls'].setup{ +vim.lsp.config('hls', { filetypes = { 'haskell', 'lhaskell', 'cabal' }, -} +}) ``` Snippet to enable the language server: >lua - require'lspconfig'.hls.setup{} + vim.lsp.enable('hls') Default config: @@ -4706,7 +4216,7 @@ Default config: ```lua { "haskell", "lhaskell" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/hls.lua:4](../lua/lspconfig/configs/hls.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/hls.lua:16](../lsp/hls.lua#L16) - `settings` : ```lua { @@ -4716,7 +4226,6 @@ Default config: } } ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -4732,7 +4241,7 @@ Start a fake ~zod with `urbit -F zod`. Start the language server at the Urbit Dojo prompt with: `|start %language-server` Snippet to enable the language server: >lua - require'lspconfig'.hoon_ls.setup{} + vim.lsp.enable('hoon_ls') Default config: @@ -4744,8 +4253,10 @@ Default config: ```lua { "hoon" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/hoon_ls.lua:2](../lua/lspconfig/configs/hoon_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -4768,13 +4279,13 @@ The code-formatting feature of the lsp can be controlled with the `provideFormat local capabilities = vim.lsp.protocol.make_client_capabilities() capabilities.textDocument.completion.completionItem.snippetSupport = true -require'lspconfig'.html.setup { +vim.lsp.config('html', { capabilities = capabilities, -} +}) ``` Snippet to enable the language server: >lua - require'lspconfig'.html.setup{} + vim.lsp.enable('html') Default config: @@ -4797,12 +4308,14 @@ Default config: provideFormatter = true } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/html.lua:4](../lua/lspconfig/configs/html.lua#L4) +- `root_markers` : + ```lua + { "package.json", ".git" } + ``` - `settings` : ```lua {} ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -4818,7 +4331,7 @@ cargo install htmx-lsp Lsp is still very much work in progress and experimental. Use at your own risk. Snippet to enable the language server: >lua - require'lspconfig'.htmx.setup{} + vim.lsp.enable('htmx') Default config: @@ -4830,8 +4343,10 @@ Default config: ```lua { "aspnetcorerazor", "astro", "astro-markdown", "blade", "clojure", "django-html", "htmldjango", "edge", "eelixir", "elixir", "ejs", "erb", "eruby", "gohtml", "gohtmltmpl", "haml", "handlebars", "hbs", "html", "htmlangular", "html-eex", "heex", "jade", "leaf", "liquid", "markdown", "mdx", "mustache", "njk", "nunjucks", "php", "razor", "slim", "twig", "javascript", "javascriptreact", "reason", "rescript", "typescript", "typescriptreact", "vue", "svelte", "templ" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/htmx.lua:2](../lua/lspconfig/configs/htmx.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -4842,7 +4357,7 @@ https://github.com/Retsediv/hydra-lsp LSP for Hydra Python package config files. Snippet to enable the language server: >lua - require'lspconfig'.hydra_lsp.setup{} + vim.lsp.enable('hydra_lsp') Default config: @@ -4854,8 +4369,10 @@ Default config: ```lua { "yaml" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/hydra_lsp.lua:4](../lua/lspconfig/configs/hydra_lsp.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -4869,7 +4386,7 @@ go install github.com/ewen-lbh/hyprls/cmd/hyprls@latest ``` Snippet to enable the language server: >lua - require'lspconfig'.hyprls.setup{} + vim.lsp.enable('hyprls') Default config: @@ -4881,8 +4398,10 @@ Default config: ```lua { "hyprlang" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/hyprls.lua:2](../lua/lspconfig/configs/hyprls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -4918,7 +4437,7 @@ latest commit on the `master` branch, and set a reminder to check the Idris2-Lsp repo for the release of a compatible versioned branch. Snippet to enable the language server: >lua - require'lspconfig'.idris2_lsp.setup{} + vim.lsp.enable('idris2_lsp') Default config: @@ -4930,7 +4449,7 @@ Default config: ```lua { "idris2" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/idris2_lsp.lua:4](../lua/lspconfig/configs/idris2_lsp.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/idris2_lsp.lua:33](../lsp/idris2_lsp.lua#L33) ------------------------------------------------------------------------------ @@ -4962,7 +4481,7 @@ settings = { ``` Snippet to enable the language server: >lua - require'lspconfig'.intelephense.setup{} + vim.lsp.enable('intelephense') Default config: @@ -4974,7 +4493,7 @@ Default config: ```lua { "php" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/intelephense.lua:4](../lua/lspconfig/configs/intelephense.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/intelephense.lua:29](../lsp/intelephense.lua#L29) ------------------------------------------------------------------------------ @@ -4985,7 +4504,7 @@ https://github.com/CFiggers/janet-lsp A Language Server Protocol implementation for Janet. Snippet to enable the language server: >lua - require'lspconfig'.janet_lsp.setup{} + vim.lsp.enable('janet_lsp') Default config: @@ -4997,8 +4516,10 @@ Default config: ```lua { "janet" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/janet_lsp.lua:4](../lua/lspconfig/configs/janet_lsp.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "project.janet", ".git" } + ``` ------------------------------------------------------------------------------ @@ -5011,7 +4532,7 @@ Java language server Point `cmd` to `lang_server_linux.sh` or the equivalent script for macOS/Windows provided by java-language-server Snippet to enable the language server: >lua - require'lspconfig'.java_language_server.setup{} + vim.lsp.enable('java_language_server') Default config: @@ -5019,7 +4540,10 @@ Default config: ```lua { "java" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/java_language_server.lua:4](../lua/lspconfig/configs/java_language_server.lua#L4) +- `root_markers` : + ```lua + { "build.gradle", "build.gradle.kts", "pom.xml", ".git" } + ``` - `settings` : ```lua {} @@ -5043,7 +4567,7 @@ and ensure that the `PATH` variable contains the `bin` directory of the extracte ```lua -- init.lua - require'lspconfig'.jdtls.setup{} + vim.lsp.enable('jdtls') ``` You can also pass extra custom jvm arguments with the JDTLS_JVM_ARGS environment variable as a space separated list of arguments, @@ -5058,17 +4582,17 @@ For automatic installation you can use the following unofficial installers/launc - [jdtls-launcher](https://github.com/eruizc-dev/jdtls-launcher) (Includes lombok support by default) ```lua -- init.lua - require'lspconfig'.jdtls.setup{ cmd = { 'jdtls' } } + vim.lsp.config('jdtls', { cmd = { 'jdtls' } }) ``` Snippet to enable the language server: >lua - require'lspconfig'.jdtls.setup{} + vim.lsp.enable('jdtls') Default config: - `cmd` : ```lua - { "jdtls", "-configuration", "/home/user/.cache/jdtls/config", "-data", "/home/user/.cache/jdtls/workspace" } + { "jdtls", "-configuration", ".//.cache/jdtls/config", "-data", ".//.cache/jdtls/workspace" } ``` - `filetypes` : ```lua @@ -5087,11 +4611,13 @@ Default config: ```lua { jvm_args = {}, - workspace = "/home/user/.cache/jdtls/workspace" + workspace = ".//.cache/jdtls/workspace" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/jdtls.lua:80](../lua/lspconfig/configs/jdtls.lua#L80) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git", "build.gradle", "build.gradle.kts", "build.xml", "pom.xml", "settings.gradle", "settings.gradle.kts" } + ``` ------------------------------------------------------------------------------ @@ -5102,7 +4628,7 @@ https://github.com/pappasam/jedi-language-server `jedi-language-server`, a language server for Python, built on top of jedi Snippet to enable the language server: >lua - require'lspconfig'.jedi_language_server.setup{} + vim.lsp.enable('jedi_language_server') Default config: @@ -5114,8 +4640,10 @@ Default config: ```lua { "python" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/jedi_language_server.lua:13](../lua/lspconfig/configs/jedi_language_server.lua#L13) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "pyproject.toml", "setup.py", "setup.cfg", "requirements.txt", "Pipfile", ".git" } + ``` ------------------------------------------------------------------------------ @@ -5136,7 +4664,7 @@ vim.filetype.add { ``` Snippet to enable the language server: >lua - require'lspconfig'.jinja_lsp.setup{} + vim.lsp.enable('jinja_lsp') Default config: @@ -5152,8 +4680,10 @@ Default config: ```lua "jinja_lsp" ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/jinja_lsp.lua:2](../lua/lspconfig/configs/jinja_lsp.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -5175,7 +4705,7 @@ vim.cmd([[au BufRead,BufNewFile *.jq setfiletype jq]]) ``` Snippet to enable the language server: >lua - require'lspconfig'.jqls.setup{} + vim.lsp.enable('jqls') Default config: @@ -5187,8 +4717,10 @@ Default config: ```lua { "jq" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/jqls.lua:2](../lua/lspconfig/configs/jqls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -5210,13 +4742,13 @@ npm i -g vscode-langservers-extracted local capabilities = vim.lsp.protocol.make_client_capabilities() capabilities.textDocument.completion.completionItem.snippetSupport = true -require'lspconfig'.jsonls.setup { +vim.lsp.config('jsonls', { capabilities = capabilities, -} +}) ``` Snippet to enable the language server: >lua - require'lspconfig'.jsonls.setup{} + vim.lsp.enable('jsonls') Default config: @@ -5234,38 +4766,10 @@ Default config: provideFormatter = true } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/jsonls.lua:2](../lua/lspconfig/configs/jsonls.lua#L2) -- `single_file_support` : `true` - - ------------------------------------------------------------------------------- -jsonnet_ls - -https://github.com/grafana/jsonnet-language-server - -A Language Server Protocol (LSP) server for Jsonnet. - -The language server can be installed with `go`: -```sh -go install github.com/grafana/jsonnet-language-server@latest -``` - -Snippet to enable the language server: >lua - require'lspconfig'.jsonnet_ls.setup{} - - -Default config: -- `cmd` : - ```lua - { "jsonnet-language-server" } - ``` -- `filetypes` : +- `root_markers` : ```lua - { "jsonnet", "libsonnet" } + { ".git" } ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/jsonnet_ls.lua:13](../lua/lspconfig/configs/jsonnet_ls.lua#L13) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/jsonnet_ls.lua:13](../lua/lspconfig/configs/jsonnet_ls.lua#L13) -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -5295,12 +4799,9 @@ Note: The julia programming language searches for global environments within the folder of `$JULIA_DEPOT_PATH` entries. By default this simply `~/.julia/environments` Snippet to enable the language server: >lua - require'lspconfig'.julials.setup{} + vim.lsp.enable('julials') -Commands: -- JuliaActivateEnv: Activate a Julia environment - Default config: - `cmd` : ```lua @@ -5310,8 +4811,11 @@ Default config: ```lua { "julia" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/julials.lua:97](../lua/lspconfig/configs/julials.lua#L97) -- `single_file_support` : `true` +- `on_attach` source (use "gF" to open): [../lsp/julials.lua:118](../lsp/julials.lua#L118) +- `root_markers` : + ```lua + { "Project.toml", "JuliaProject.toml" } + ``` ------------------------------------------------------------------------------ @@ -5322,7 +4826,7 @@ https://github.com/terror/just-lsp `just-lsp` is an LSP for just built on top of the tree-sitter-just parser. Snippet to enable the language server: >lua - require'lspconfig'.just.setup{} + vim.lsp.enable('just') Default config: @@ -5334,8 +4838,10 @@ Default config: ```lua { "just" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/just.lua:2](../lua/lspconfig/configs/just.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -5346,7 +4852,7 @@ https://github.com/kcl-lang/kcl.nvim Language server for the KCL configuration and policy language. Snippet to enable the language server: >lua - require'lspconfig'.kcl.setup{} + vim.lsp.enable('kcl') Default config: @@ -5358,7 +4864,10 @@ Default config: ```lua { "kcl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/kcl.lua:4](../lua/lspconfig/configs/kcl.lua#L4) +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -5368,7 +4877,7 @@ https://koka-lang.github.io/koka/doc/index.html Koka is a functional programming language with effect types and handlers. Snippet to enable the language server: >lua - require'lspconfig'.koka.setup{} + vim.lsp.enable('koka') Default config: @@ -5380,31 +4889,21 @@ Default config: ```lua { "koka" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/koka.lua:2](../lua/lspconfig/configs/koka.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ kotlin_language_server A kotlin language server which was developed for internal usage and - released afterwards. Maintaining is not done by the original author, - but by fwcd. - - It is built via gradle and developed on github. - Source and additional description: - https://github.com/fwcd/kotlin-language-server - - This server requires vim to be aware of the kotlin-filetype. - You could refer for this capability to: - https://github.com/udalov/kotlin-vim (recommended) - Note that there is no LICENSE specified yet. - - For faster startup, you can setup caching by specifying a storagePath - in the init_options. The default is your home directory. + released afterwards. Maintaining is not done by the original author, + but by fwcd. Snippet to enable the language server: >lua - require'lspconfig'.kotlin_language_server.setup{} + vim.lsp.enable('kotlin_language_server') Default config: @@ -5420,7 +4919,10 @@ Default config: ```lua {} ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/kotlin_language_server.lua:20](../lua/lspconfig/configs/kotlin_language_server.lua#L20) +- `root_markers` : + ```lua + { "settings.gradle", "settings.gradle.kts", "build.xml", "pom.xml", "build.gradle", "build.gradle.kts" } + ``` ------------------------------------------------------------------------------ @@ -5431,7 +4933,7 @@ https://github.com/mistweaverco/kulala-ls A minimal language server for HTTP syntax. Snippet to enable the language server: >lua - require'lspconfig'.kulala_ls.setup{} + vim.lsp.enable('kulala_ls') Default config: @@ -5443,8 +4945,10 @@ Default config: ```lua { "http" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/kulala_ls.lua:2](../lua/lspconfig/configs/kulala_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -5465,7 +4969,7 @@ that plugin fully handles the setup of the Lean language server, and you shouldn't set up `lean3ls` both with it and `lspconfig`. Snippet to enable the language server: >lua - require'lspconfig'.lean3ls.setup{} + vim.lsp.enable('lean3ls') Default config: @@ -5481,41 +4985,7 @@ Default config: ```lua "utf-32" ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/lean3ls.lua:4](../lua/lspconfig/configs/lean3ls.lua#L4) -- `single_file_support` : `true` - - ------------------------------------------------------------------------------- -leanls - -https://github.com/leanprover/lean4 - -Lean installation instructions can be found -[here](https://leanprover-community.github.io/get_started.html#regular-install). - -The Lean language server is included in any Lean installation and -does not require any additional packages. - -Note: that if you're using [lean.nvim](https://github.com/Julian/lean.nvim), -that plugin fully handles the setup of the Lean language server, -and you shouldn't set up `leanls` both with it and `lspconfig`. - -Snippet to enable the language server: >lua - require'lspconfig'.leanls.setup{} - - -Default config: -- `cmd` : - ```lua - { "lake", "serve", "--" } - ``` -- `filetypes` : - ```lua - { "lean" } - ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/leanls.lua:4](../lua/lspconfig/configs/leanls.lua#L4) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/leanls.lua:4](../lua/lspconfig/configs/leanls.lua#L4) -- `single_file_support` : `true` +- `root_dir` source (use "gF" to open): [../lsp/lean3ls.lua:18](../lsp/lean3ls.lua#L18) ------------------------------------------------------------------------------ @@ -5531,7 +5001,7 @@ cargo install --features="lsp" lelwel ``` Snippet to enable the language server: >lua - require'lspconfig'.lelwel_ls.setup{} + vim.lsp.enable('lelwel_ls') Default config: @@ -5543,7 +5013,10 @@ Default config: ```lua { "llw" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/lelwel_ls.lua:2](../lua/lspconfig/configs/lelwel_ls.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -5556,7 +5029,7 @@ The easiest way to install the server is to get a binary from https://github.com NOTE to macOS users: Binaries from unidentified developers are blocked by default. If you trust the downloaded binary, run it once, cancel the prompt, then remove the binary from Gatekeeper quarantine with `xattr -d com.apple.quarantine lemminx`. It should now run without being blocked. Snippet to enable the language server: >lua - require'lspconfig'.lemminx.setup{} + vim.lsp.enable('lemminx') Default config: @@ -5568,8 +5041,10 @@ Default config: ```lua { "xml", "xsd", "xsl", "xslt", "svg" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/lemminx.lua:2](../lua/lspconfig/configs/lemminx.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -5585,7 +5060,7 @@ Follow the [Detailed Installation Instructions](https://github.com/lexical-lsp/l This is because nvim-lspconfig does not make assumptions about your path. Snippet to enable the language server: >lua - require'lspconfig'.lexical.setup{} + vim.lsp.enable('lexical') Default config: @@ -5593,8 +5068,10 @@ Default config: ```lua { "elixir", "eelixir", "heex", "surface" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/lexical.lua:4](../lua/lspconfig/configs/lexical.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "mix.exs", ".git" } + ``` ------------------------------------------------------------------------------ @@ -5611,7 +5088,7 @@ completion/code actions. See the [wiki docs](https://github.com/SilasMarvin/lsp- [examples](https://github.com/SilasMarvin/lsp-ai/blob/main/examples/nvim) for more information. Snippet to enable the language server: >lua - require'lspconfig'.lsp_ai.setup{} + vim.lsp.enable('lsp_ai') Default config: @@ -5632,7 +5109,6 @@ Default config: models = vim.empty_dict() } ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -5661,7 +5137,7 @@ vim.cmd [[ autocmd BufRead,BufNewFile *.org set filetype=org ]] ``` Snippet to enable the language server: >lua - require'lspconfig'.ltex.setup{} + vim.lsp.enable('ltex') Default config: @@ -5673,8 +5149,11 @@ Default config: ```lua { "bib", "gitcommit", "markdown", "org", "plaintex", "rst", "rnoweb", "tex", "pandoc", "quarto", "rmd", "context", "html", "xhtml", "mail", "text" } ``` -- `get_language_id` source (use "gF" to visit): [../lua/lspconfig/configs/ltex.lua:51](../lua/lspconfig/configs/ltex.lua#L51) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ltex.lua:51](../lua/lspconfig/configs/ltex.lua#L51) +- `get_language_id` source (use "gF" to open): [../lsp/ltex.lua:73](../lsp/ltex.lua#L73) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua { @@ -5683,7 +5162,6 @@ Default config: } } ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -5712,7 +5190,7 @@ vim.cmd [[ autocmd BufRead,BufNewFile *.org set filetype=org ]] ``` Snippet to enable the language server: >lua - require'lspconfig'.ltex_plus.setup{} + vim.lsp.enable('ltex_plus') Default config: @@ -5724,8 +5202,11 @@ Default config: ```lua { "bib", "context", "gitcommit", "html", "markdown", "org", "pandoc", "plaintex", "quarto", "mail", "mdx", "rmd", "rnoweb", "rst", "tex", "text", "typst", "xhtml" } ``` -- `get_language_id` source (use "gF" to visit): [../lua/lspconfig/configs/ltex_plus.lua:16](../lua/lspconfig/configs/ltex_plus.lua#L16) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ltex_plus.lua:16](../lua/lspconfig/configs/ltex_plus.lua#L16) +- `get_language_id` source (use "gF" to open): [../lsp/ltex_plus.lua:38](../lsp/ltex_plus.lua#L38) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua { @@ -5734,7 +5215,6 @@ Default config: } } ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -5753,7 +5233,7 @@ analysis, and location handling for plugins on runtime path, you can use the fol settings. ```lua -require'lspconfig'.lua_ls.setup { +vim.lsp.config('lua_ls', { on_init = function(client) if client.workspace_folders then local path = client.workspace_folders[1].name @@ -5785,7 +5265,7 @@ require'lspconfig'.lua_ls.setup { settings = { Lua = {} } -} +}) ``` See `lua-language-server`'s [documentation](https://luals.github.io/wiki/settings/) for an explanation of the above fields: @@ -5793,7 +5273,7 @@ See `lua-language-server`'s [documentation](https://luals.github.io/wiki/setting * [Lua.workspace.library](https://luals.github.io/wiki/settings/#workspacelibrary) Snippet to enable the language server: >lua - require'lspconfig'.lua_ls.setup{} + vim.lsp.enable('lua_ls') Default config: @@ -5805,21 +5285,29 @@ Default config: ```lua { "lua" } ``` -- `log_level` : +- `root_markers` : ```lua - 2 + { ".luarc.json", ".luarc.jsonc", ".luacheckrc", ".stylua.toml", "stylua.toml", "selene.toml", "selene.yml", ".git" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/lua_ls.lua:15](../lua/lspconfig/configs/lua_ls.lua#L15) -- `single_file_support` : `true` ------------------------------------------------------------------------------ luau_lsp +https://github.com/JohnnyMorganz/luau-lsp + +Language server for the [Luau](https://luau-lang.org/) language. +`luau-lsp` can be installed by downloading one of the release assets available at https://github.com/JohnnyMorganz/luau-lsp. + +You might also have to set up automatic filetype detection for Luau files, for example like so: + +```vim +autocmd BufRead,BufNewFile *.luau setf luau +``` Snippet to enable the language server: >lua - require'lspconfig'.luau_lsp.setup{} + vim.lsp.enable('luau_lsp') Default config: @@ -5831,8 +5319,10 @@ Default config: ```lua { "luau" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/luau_lsp.lua:2](../lua/lspconfig/configs/luau_lsp.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -5846,17 +5336,17 @@ For manual installation, utilize the official [NPM package](https://www.npmjs.co Then, configure `cmd` to run the Node script at the unpacked location: ```lua -require'lspconfig'.lwc_ls.setup { +vim.lsp.config('lwc_ls', { cmd = { 'node', '/path/to/node_modules/@salesforce/lwc-language-server/bin/lwc-language-server.js', '--stdio' } -} +}) ``` Snippet to enable the language server: >lua - require'lspconfig'.lwc_ls.setup{} + vim.lsp.enable('lwc_ls') Default config: @@ -5876,7 +5366,10 @@ Default config: } } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/lwc_ls.lua:4](../lua/lspconfig/configs/lwc_ls.lua#L4) +- `root_markers` : + ```lua + { "sfdx-project.json" } + ``` ------------------------------------------------------------------------------ @@ -5899,7 +5392,7 @@ vim.g.asmsyntax = 'asm68k' ``` Snippet to enable the language server: >lua - require'lspconfig'.m68k.setup{} + vim.lsp.enable('m68k') Default config: @@ -5911,8 +5404,10 @@ Default config: ```lua { "asm68k" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/m68k.lua:4](../lua/lspconfig/configs/m68k.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "Makefile", ".git" } + ``` ------------------------------------------------------------------------------ @@ -5928,14 +5423,9 @@ Inspired by and compatible with Obsidian. Check the readme to see how to properly setup. Snippet to enable the language server: >lua - require'lspconfig'.markdown_oxide.setup{} + vim.lsp.enable('markdown_oxide') -Commands: -- Today: Open today's daily note -- Tomorrow: Open tomorrow's daily note -- Yesterday: Open yesterday's daily note - Default config: - `cmd` : ```lua @@ -5945,8 +5435,11 @@ Default config: ```lua { "markdown" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/markdown_oxide.lua:2](../lua/lspconfig/configs/markdown_oxide.lua#L2) -- `single_file_support` : `true` +- `on_attach` source (use "gF" to open): [../lsp/markdown_oxide.lua:11](../lsp/markdown_oxide.lua#L11) +- `root_markers` : + ```lua + { ".git", ".obsidian", ".moxide.toml" } + ``` ------------------------------------------------------------------------------ @@ -5954,15 +5447,8 @@ marko-js https://github.com/marko-js/language-server - Using the Language Server Protocol to improve Marko's developer experience. - - Can be installed via npm: - ``` - npm i -g @marko/language-server - ``` - Snippet to enable the language server: >lua - require'lspconfig'.marko-js.setup{} + vim.lsp.enable('marko-js') Default config: @@ -5974,7 +5460,10 @@ Default config: ```lua { "marko" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/marko-js.lua:2](../lua/lspconfig/configs/marko-js.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -5989,7 +5478,7 @@ Marksman works on MacOS, Linux, and Windows and is distributed as a self-contain Pre-built binaries can be downloaded from https://github.com/artempyanykh/marksman/releases Snippet to enable the language server: >lua - require'lspconfig'.marksman.setup{} + vim.lsp.enable('marksman') Default config: @@ -6001,78 +5490,10 @@ Default config: ```lua { "markdown", "markdown.mdx" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/marksman.lua:7](../lua/lspconfig/configs/marksman.lua#L7) -- `single_file_support` : `true` - - ------------------------------------------------------------------------------- -matlab_ls - -https://github.com/mathworks/MATLAB-language-server - -MATLAB® language server implements the Microsoft® Language Server Protocol for the MATLAB language. - -Snippet to enable the language server: >lua - require'lspconfig'.matlab_ls.setup{} - - -Default config: -- `cmd` : - ```lua - { "matlab-language-server", "--stdio" } - ``` -- `filetypes` : - ```lua - { "matlab" } - ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/matlab_ls.lua:2](../lua/lspconfig/configs/matlab_ls.lua#L2) -- `settings` : - ```lua - { - MATLAB = { - indexWorkspace = false, - installPath = "", - matlabConnectionTiming = "onStart", - telemetry = true - } - } - ``` -- `single_file_support` : `false` - - ------------------------------------------------------------------------------- -mdx_analyzer - -https://github.com/mdx-js/mdx-analyzer - -`mdx-analyzer`, a language server for MDX - -Snippet to enable the language server: >lua - require'lspconfig'.mdx_analyzer.setup{} - - -Default config: -- `cmd` : - ```lua - { "mdx-language-server", "--stdio" } - ``` -- `filetypes` : - ```lua - { "mdx" } - ``` -- `init_options` : - ```lua - { - typescript = {} - } - ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/mdx_analyzer.lua:9](../lua/lspconfig/configs/mdx_analyzer.lua#L9) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/mdx_analyzer.lua:9](../lua/lspconfig/configs/mdx_analyzer.lua#L9) -- `settings` : +- `root_markers` : ```lua - {} + { ".marksman.toml", ".git" } ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -6083,7 +5504,7 @@ https://github.com/JCWasmx86/mesonlsp An unofficial, unendorsed language server for meson written in C++ Snippet to enable the language server: >lua - require'lspconfig'.mesonlsp.setup{} + vim.lsp.enable('mesonlsp') Default config: @@ -6095,7 +5516,10 @@ Default config: ```lua { "meson" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/mesonlsp.lua:4](../lua/lspconfig/configs/mesonlsp.lua#L4) +- `root_markers` : + ```lua + { "meson.build", "meson_options.txt", "meson.options", ".git" } + ``` ------------------------------------------------------------------------------ @@ -6114,7 +5538,7 @@ Note: that if you're using [nvim-metals](https://github.com/scalameta/nvim-metal To install Metals, make sure to have [coursier](https://get-coursier.io/docs/cli-installation) installed, and once you do you can install the latest Metals with `cs install metals`. Snippet to enable the language server: >lua - require'lspconfig'.metals.setup{} + vim.lsp.enable('metals') Default config: @@ -6144,11 +5568,10 @@ Default config: statusBarProvider = "show-message" } ``` -- `message_level` : +- `root_markers` : ```lua - 4 + { "build.sbt", "build.sc", "build.gradle", "pom.xml" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/metals.lua:4](../lua/lspconfig/configs/metals.lua#L4) ------------------------------------------------------------------------------ @@ -6166,7 +5589,7 @@ To use with nvim: 4. Move `target/release/lang-srv` to somewhere on your $PATH as `millet` Snippet to enable the language server: >lua - require'lspconfig'.millet.setup{} + vim.lsp.enable('millet') Default config: @@ -6178,8 +5601,10 @@ Default config: ```lua { "sml" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/millet.lua:4](../lua/lspconfig/configs/millet.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "millet.toml" } + ``` ------------------------------------------------------------------------------ @@ -6191,7 +5616,7 @@ Install Mint using the [instructions](https://www.mint-lang.com/install). The language server is included since version 0.12.0. Snippet to enable the language server: >lua - require'lspconfig'.mint.setup{} + vim.lsp.enable('mint') Default config: @@ -6203,8 +5628,10 @@ Default config: ```lua { "mint" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/mint.lua:4](../lua/lspconfig/configs/mint.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "mint.json", ".git" } + ``` ------------------------------------------------------------------------------ @@ -6217,7 +5644,7 @@ The Language Server for the LLVM MLIR language `mlir-lsp-server` can be installed at the llvm-project repository (https://github.com/llvm/llvm-project) Snippet to enable the language server: >lua - require'lspconfig'.mlir_lsp_server.setup{} + vim.lsp.enable('mlir_lsp_server') Default config: @@ -6229,8 +5656,10 @@ Default config: ```lua { "mlir" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/mlir_lsp_server.lua:2](../lua/lspconfig/configs/mlir_lsp_server.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -6243,7 +5672,7 @@ The Language Server for the LLVM PDLL language `mlir-pdll-lsp-server` can be installed at the llvm-project repository (https://github.com/llvm/llvm-project) Snippet to enable the language server: >lua - require'lspconfig'.mlir_pdll_lsp_server.setup{} + vim.lsp.enable('mlir_pdll_lsp_server') Default config: @@ -6255,7 +5684,10 @@ Default config: ```lua { "pdll" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/mlir_pdll_lsp_server.lua:4](../lua/lspconfig/configs/mlir_pdll_lsp_server.lua#L4) +- `root_markers` : + ```lua + { "pdll_compile_commands.yml", ".git" } + ``` ------------------------------------------------------------------------------ @@ -6269,7 +5701,7 @@ Requires [mm0-rs](https://github.com/digama0/mm0/tree/master/mm0-rs) to be insta and available on the `PATH`. Snippet to enable the language server: >lua - require'lspconfig'.mm0_ls.setup{} + vim.lsp.enable('mm0_ls') Default config: @@ -6281,8 +5713,10 @@ Default config: ```lua { "metamath-zero" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/mm0_ls.lua:2](../lua/lspconfig/configs/mm0_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -6295,7 +5729,7 @@ https://github.com/modularml/mojo Mojo is a new programming language that bridges the gap between research and production by combining Python syntax and ecosystem with systems programming and metaprogramming features. Snippet to enable the language server: >lua - require'lspconfig'.mojo.setup{} + vim.lsp.enable('mojo') Default config: @@ -6307,8 +5741,10 @@ Default config: ```lua { "mojo" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/mojo.lua:2](../lua/lspconfig/configs/mojo.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -6319,7 +5755,7 @@ https://github.com/dfinity/vscode-motoko Language server for the Motoko programming language. Snippet to enable the language server: >lua - require'lspconfig'.motoko_lsp.setup{} + vim.lsp.enable('motoko_lsp') Default config: @@ -6337,8 +5773,10 @@ Default config: formatter = "auto" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/motoko_lsp.lua:4](../lua/lspconfig/configs/motoko_lsp.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "dfx.json", ".git" } + ``` ------------------------------------------------------------------------------ @@ -6357,7 +5795,7 @@ cargo install --git https://github.com/move-language/move move-analyzer See [`move-analyzer`'s doc](https://github.com/move-language/move/blob/1b258a06e3c7d2bc9174578aac92cca3ac19de71/language/move-analyzer/editors/code/README.md#how-to-install) for details. Snippet to enable the language server: >lua - require'lspconfig'.move_analyzer.setup{} + vim.lsp.enable('move_analyzer') Default config: @@ -6369,7 +5807,10 @@ Default config: ```lua { "move" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/move_analyzer.lua:4](../lua/lspconfig/configs/move_analyzer.lua#L4) +- `root_markers` : + ```lua + { "Move.toml" } + ``` ------------------------------------------------------------------------------ @@ -6381,9 +5822,9 @@ MSBuild Project Tools Server can be installed by following the README.MD on the Example config: ```lua -lspconfig.msbuild_project_tools_server.setup { +vim.lsp.config('msbuild_project_tools_server', { cmd = {'dotnet', '/path/to/server/MSBuildProjectTools.LanguageServer.Host.dll'} -} +}) ``` There's no builtin filetypes for msbuild files, would require some filetype aliases: @@ -6408,7 +5849,7 @@ vim.treesitter.language.register('xml', { 'msbuild' }) ``` Snippet to enable the language server: >lua - require'lspconfig'.msbuild_project_tools_server.setup{} + vim.lsp.enable('msbuild_project_tools_server') Default config: @@ -6424,7 +5865,7 @@ Default config: ```lua {} ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/msbuild_project_tools_server.lua:5](../lua/lspconfig/configs/msbuild_project_tools_server.lua#L5) +- `root_dir` source (use "gF" to open): [../lsp/msbuild_project_tools_server.lua:37](../lsp/msbuild_project_tools_server.lua#L37) ------------------------------------------------------------------------------ @@ -6433,7 +5874,7 @@ muon https://muon.build Snippet to enable the language server: >lua - require'lspconfig'.muon.setup{} + vim.lsp.enable('muon') Default config: @@ -6445,7 +5886,7 @@ Default config: ```lua { "meson" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/muon.lua:4](../lua/lspconfig/configs/muon.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/muon.lua:4](../lsp/muon.lua#L4) ------------------------------------------------------------------------------ @@ -6460,7 +5901,7 @@ pip install mutt-language-server ``` Snippet to enable the language server: >lua - require'lspconfig'.mutt_ls.setup{} + vim.lsp.enable('mutt_ls') Default config: @@ -6472,12 +5913,14 @@ Default config: ```lua { "muttrc", "neomuttrc" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/mutt_ls.lua:2](../lua/lspconfig/configs/mutt_ls.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua {} ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -6502,13 +5945,13 @@ vim.api.nvim_create_autocmd({ "BufNewFile", "BufRead" }, { pattern = { "*.nelua" **By default, nelua-lsp doesn't have a `cmd` set.** This is because nvim-lspconfig does not make assumptions about your path. You must add the following to your init.vim or init.lua to set `cmd` to the absolute path ($HOME and ~ are not expanded) of the unzipped run script or binary. ```lua -require'lspconfig'.nelua_lsp.setup { +vim.lsp.config('nelua_lsp.setup, { cmd = { "nelua", "-L", "/path/to/nelua-lsp/", "--script", "/path/to/nelua-lsp/nelua-lsp.lua" }, -} +}) ``` Snippet to enable the language server: >lua - require'lspconfig'.nelua_lsp.setup{} + vim.lsp.enable('nelua_lsp') Default config: @@ -6516,8 +5959,10 @@ Default config: ```lua { "nelua" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/nelua_lsp.lua:4](../lua/lspconfig/configs/nelua_lsp.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "Makefile", ".git", "*.nelua" } + ``` ------------------------------------------------------------------------------ @@ -6534,13 +5979,13 @@ Neovim does not currently include built-in snippets. `neocmakelsp` only provides local capabilities = vim.lsp.protocol.make_client_capabilities() capabilities.textDocument.completion.completionItem.snippetSupport = true -require'lspconfig'.neocmake.setup { +vim.lsp.config('neocmake', { capabilities = capabilities, -} +}) ``` Snippet to enable the language server: >lua - require'lspconfig'.neocmake.setup{} + vim.lsp.enable('neocmake') Default config: @@ -6552,8 +5997,10 @@ Default config: ```lua { "cmake" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/neocmake.lua:4](../lua/lspconfig/configs/neocmake.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git", "build", "cmake" } + ``` ------------------------------------------------------------------------------ @@ -6569,10 +6016,9 @@ Requirements: If you have installed nextflow language server, you can set the `cmd` custom path as follow: ```lua -require'lspconfig'.nextflow_ls.setup{ +vim.lsp.config('nextflow_ls', { cmd = { 'java', '-jar', 'nextflow-language-server-all.jar' }, filetypes = { 'nextflow' }, - root_dir = util.root_pattern('nextflow.config', '.git'), settings = { nextflow = { files = { @@ -6580,11 +6026,11 @@ require'lspconfig'.nextflow_ls.setup{ }, }, }, -} +}) ``` Snippet to enable the language server: >lua - require'lspconfig'.nextflow_ls.setup{} + vim.lsp.enable('nextflow_ls') Default config: @@ -6596,7 +6042,10 @@ Default config: ```lua { "nextflow" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/nextflow_ls.lua:4](../lua/lspconfig/configs/nextflow_ls.lua#L4) +- `root_markers` : + ```lua + { "nextflow.config", ".git" } + ``` - `settings` : ```lua { @@ -6617,7 +6066,7 @@ https://github.com/elixir-tools/next-ls **By default, next-ls does not set its `cmd`. Please see the following [detailed instructions](https://www.elixir-tools.dev/docs/next-ls/installation/) for possible installation methods.** Snippet to enable the language server: >lua - require'lspconfig'.nextls.setup{} + vim.lsp.enable('nextls') Default config: @@ -6625,8 +6074,10 @@ Default config: ```lua { "elixir", "eelixir", "heex", "surface" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/nextls.lua:4](../lua/lspconfig/configs/nextls.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "mix.exs", ".git" } + ``` ------------------------------------------------------------------------------ @@ -6641,7 +6092,7 @@ pip install -U nginx-language-server ``` Snippet to enable the language server: >lua - require'lspconfig'.nginx_language_server.setup{} + vim.lsp.enable('nginx_language_server') Default config: @@ -6653,8 +6104,10 @@ Default config: ```lua { "nginx" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/nginx_language_server.lua:4](../lua/lspconfig/configs/nginx_language_server.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "nginx.conf", ".git" } + ``` ------------------------------------------------------------------------------ @@ -6685,7 +6138,7 @@ In order to have lspconfig detect Nickel filetypes (a prerequisite for autostart install the [Nickel vim plugin](https://github.com/nickel-lang/vim-nickel). Snippet to enable the language server: >lua - require'lspconfig'.nickel_ls.setup{} + vim.lsp.enable('nickel_ls') Default config: @@ -6697,7 +6150,10 @@ Default config: ```lua { "ncl", "nickel" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/nickel_ls.lua:2](../lua/lspconfig/configs/nickel_ls.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -6713,7 +6169,7 @@ Check the repository README for more information. _See an example config at https://github.com/oxalica/nil/blob/main/dev/nvim-lsp.nix._ Snippet to enable the language server: >lua - require'lspconfig'.nil_ls.setup{} + vim.lsp.enable('nil_ls') Default config: @@ -6725,8 +6181,10 @@ Default config: ```lua { "nix" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/nil_ls.lua:4](../lua/lspconfig/configs/nil_ls.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "flake.nix", ".git" } + ``` ------------------------------------------------------------------------------ @@ -6741,7 +6199,7 @@ nimble install nimlangserver ``` Snippet to enable the language server: >lua - require'lspconfig'.nim_langserver.setup{} + vim.lsp.enable('nim_langserver') Default config: @@ -6753,8 +6211,7 @@ Default config: ```lua { "nim" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/nim_langserver.lua:4](../lua/lspconfig/configs/nim_langserver.lua#L4) -- `single_file_support` : `true` +- `root_dir` source (use "gF" to open): [../lsp/nim_langserver.lua:12](../lsp/nim_langserver.lua#L12) ------------------------------------------------------------------------------ @@ -6769,7 +6226,7 @@ nimble install nimlsp ``` Snippet to enable the language server: >lua - require'lspconfig'.nimls.setup{} + vim.lsp.enable('nimls') Default config: @@ -6781,8 +6238,7 @@ Default config: ```lua { "nim" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/nimls.lua:4](../lua/lspconfig/configs/nimls.lua#L4) -- `single_file_support` : `true` +- `root_dir` source (use "gF" to open): [../lsp/nimls.lua:12](../lsp/nimls.lua#L12) ------------------------------------------------------------------------------ @@ -6796,7 +6252,7 @@ If you are using Nix with Flakes support, run `nix profile install github:nix-co Check the repository README for more information. Snippet to enable the language server: >lua - require'lspconfig'.nixd.setup{} + vim.lsp.enable('nixd') Default config: @@ -6808,8 +6264,10 @@ Default config: ```lua { "nix" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/nixd.lua:4](../lua/lspconfig/configs/nixd.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "flake.nix", "git" } + ``` ------------------------------------------------------------------------------ @@ -6824,7 +6282,7 @@ Add the executable to your system or vim PATH and it will be set to go. No configuration option is needed unless you choose not to add `nomad-lsp` executable to the PATH. You should know what you are doing if you choose so. ```lua -require('lspconfig').nomad_lsp.setup{ } +vim.lsp.enable('nomad_lsp') ``` However, a `hcl.nomad` or `nomad` filetype should be defined. @@ -6832,7 +6290,7 @@ However, a `hcl.nomad` or `nomad` filetype should be defined. Description of your jobs should be written in `.nomad` files for the LSP client to configure the server's `root_dir` configuration option. Snippet to enable the language server: >lua - require'lspconfig'.nomad_lsp.setup{} + vim.lsp.enable('nomad_lsp') Default config: @@ -6844,7 +6302,7 @@ Default config: ```lua { "hcl.nomad", "nomad" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/nomad_lsp.lua:9](../lua/lspconfig/configs/nomad_lsp.lua#L9) +- `root_dir` source (use "gF" to open): [../lsp/nomad_lsp.lua:25](../lsp/nomad_lsp.lua#L25) ------------------------------------------------------------------------------ @@ -6854,16 +6312,16 @@ https://github.com/nokia/ntt Installation instructions can be found [here](https://github.com/nokia/ntt#Install). Can be configured by passing a "settings" object to `ntt.setup{}`: ```lua -require('lspconfig').ntt.setup{ +vim.lsp.config('ntt', { settings = { ntt = { } } -} +}) ``` Snippet to enable the language server: >lua - require'lspconfig'.ntt.setup{} + vim.lsp.enable('ntt') Default config: @@ -6875,7 +6333,10 @@ Default config: ```lua { "ttcn" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ntt.lua:5](../lua/lspconfig/configs/ntt.lua#L5) +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -6886,7 +6347,7 @@ https://github.com/nushell/nushell Nushell built-in language server. Snippet to enable the language server: >lua - require'lspconfig'.nushell.setup{} + vim.lsp.enable('nushell') Default config: @@ -6898,8 +6359,10 @@ Default config: ```lua { "nu" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/nushell.lua:2](../lua/lspconfig/configs/nushell.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -6915,7 +6378,7 @@ npm i -g nxls ``` Snippet to enable the language server: >lua - require'lspconfig'.nxls.setup{} + vim.lsp.enable('nxls') Default config: @@ -6927,7 +6390,10 @@ Default config: ```lua { "json", "jsonc" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/nxls.lua:4](../lua/lspconfig/configs/nxls.lua#L4) +- `root_markers` : + ```lua + { "nx.json", ".git" } + ``` ------------------------------------------------------------------------------ @@ -6941,7 +6407,7 @@ npm install -g ocaml-language-server ``` Snippet to enable the language server: >lua - require'lspconfig'.ocamlls.setup{} + vim.lsp.enable('ocamlls') Default config: @@ -6953,7 +6419,7 @@ Default config: ```lua { "ocaml", "reason" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ocamlls.lua:4](../lua/lspconfig/configs/ocamlls.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/ocamlls.lua:11](../lsp/ocamlls.lua#L11) ------------------------------------------------------------------------------ @@ -6969,7 +6435,7 @@ opam install ocaml-lsp-server ``` Snippet to enable the language server: >lua - require'lspconfig'.ocamllsp.setup{} + vim.lsp.enable('ocamllsp') Default config: @@ -6981,8 +6447,8 @@ Default config: ```lua { "ocaml", "menhir", "ocamlinterface", "ocamllex", "reason", "dune" } ``` -- `get_language_id` source (use "gF" to visit): [../lua/lspconfig/configs/ocamllsp.lua:17](../lua/lspconfig/configs/ocamllsp.lua#L17) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ocamllsp.lua:17](../lua/lspconfig/configs/ocamllsp.lua#L17) +- `get_language_id` source (use "gF" to open): [../lsp/ocamllsp.lua:26](../lsp/ocamllsp.lua#L26) +- `root_dir` source (use "gF" to open): [../lsp/ocamllsp.lua:26](../lsp/ocamllsp.lua#L26) ------------------------------------------------------------------------------ @@ -6990,10 +6456,10 @@ ols https://github.com/DanielGavin/ols - `Odin Language Server`. +`Odin Language Server`. Snippet to enable the language server: >lua - require'lspconfig'.ols.setup{} + vim.lsp.enable('ols') Default config: @@ -7005,97 +6471,7 @@ Default config: ```lua { "odin" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ols.lua:4](../lua/lspconfig/configs/ols.lua#L4) - - ------------------------------------------------------------------------------- -omnisharp - -https://github.com/omnisharp/omnisharp-roslyn -OmniSharp server based on Roslyn workspaces - -`omnisharp-roslyn` can be installed by downloading and extracting a release from [here](https://github.com/OmniSharp/omnisharp-roslyn/releases). -OmniSharp can also be built from source by following the instructions [here](https://github.com/omnisharp/omnisharp-roslyn#downloading-omnisharp). - -OmniSharp requires the [dotnet-sdk](https://dotnet.microsoft.com/download) to be installed. - -**By default, omnisharp-roslyn doesn't have a `cmd` set.** This is because nvim-lspconfig does not make assumptions about your path. You must add the following to your init.vim or init.lua to set `cmd` to the absolute path ($HOME and ~ are not expanded) of the unzipped run script or binary. - -For `go_to_definition` to work fully, extended `textDocument/definition` handler is needed, for example see [omnisharp-extended-lsp.nvim](https://github.com/Hoffs/omnisharp-extended-lsp.nvim) - -```lua -require'lspconfig'.omnisharp.setup { - cmd = { "dotnet", "/path/to/omnisharp/OmniSharp.dll" }, - - settings = { - FormattingOptions = { - -- Enables support for reading code style, naming convention and analyzer - -- settings from .editorconfig. - EnableEditorConfigSupport = true, - -- Specifies whether 'using' directives should be grouped and sorted during - -- document formatting. - OrganizeImports = nil, - }, - MsBuild = { - -- If true, MSBuild project system will only load projects for files that - -- were opened in the editor. This setting is useful for big C# codebases - -- and allows for faster initialization of code navigation features only - -- for projects that are relevant to code that is being edited. With this - -- setting enabled OmniSharp may load fewer projects and may thus display - -- incomplete reference lists for symbols. - LoadProjectsOnDemand = nil, - }, - RoslynExtensionsOptions = { - -- Enables support for roslyn analyzers, code fixes and rulesets. - EnableAnalyzersSupport = nil, - -- Enables support for showing unimported types and unimported extension - -- methods in completion lists. When committed, the appropriate using - -- directive will be added at the top of the current file. This option can - -- have a negative impact on initial completion responsiveness, - -- particularly for the first few completion sessions after opening a - -- solution. - EnableImportCompletion = nil, - -- Only run analyzers against open files when 'enableRoslynAnalyzers' is - -- true - AnalyzeOpenDocumentsOnly = nil, - }, - Sdk = { - -- Specifies whether to include preview versions of the .NET SDK when - -- determining which version to use for project loading. - IncludePrereleases = true, - }, - }, -} -``` - -Snippet to enable the language server: >lua - require'lspconfig'.omnisharp.setup{} - - -Default config: -- `filetypes` : - ```lua - { "cs", "vb" } - ``` -- `init_options` : - ```lua - {} - ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/omnisharp.lua:4](../lua/lspconfig/configs/omnisharp.lua#L4) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/omnisharp.lua:4](../lua/lspconfig/configs/omnisharp.lua#L4) -- `settings` : - ```lua - { - FormattingOptions = { - EnableEditorConfigSupport = true - }, - MsBuild = {}, - RoslynExtensionsOptions = {}, - Sdk = { - IncludePrereleases = true - } - } - ``` +- `root_dir` source (use "gF" to open): [../lsp/ols.lua:8](../lsp/ols.lua#L8) ------------------------------------------------------------------------------ @@ -7108,7 +6484,7 @@ Build instructions can be found [here](https://github.com/Galarius/opencl-langua Prebuilt binaries are available for Linux, macOS and Windows [here](https://github.com/Galarius/opencl-language-server/releases). Snippet to enable the language server: >lua - require'lspconfig'.opencl_ls.setup{} + vim.lsp.enable('opencl_ls') Default config: @@ -7120,51 +6496,10 @@ Default config: ```lua { "opencl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/opencl_ls.lua:2](../lua/lspconfig/configs/opencl_ls.lua#L2) - - ------------------------------------------------------------------------------- -openedge_ls - -[Language server](https://github.com/vscode-abl/vscode-abl) for Progress OpenEdge ABL. - -For manual installation, download abl-lsda.jar from the [VSCode extension](https://github.com/vscode-abl/vscode-abl/releases/latest). - -Configuration - -```lua -require('lspconfig').openedge_ls.setup { - oe_jar_path = '/path/to/abl-lsda.jar', - debug = false, -- Set to true for debug logging - trace = false, -- Set to true for trace logging (REALLY verbose) - init_options = { - abl = { - configuration = { - runtimes = { - { name = '12.8', path = '/opt/progress/dlc' } - }, - maxThreads = 1 - }, - completion = { - upperCase = false - }, - buildMode = 1 -- Build all - } - } -} -``` - -Snippet to enable the language server: >lua - require'lspconfig'.openedge_ls.setup{} - - -Default config: -- `filetypes` : +- `root_markers` : ```lua - { "progress" } + { ".git" } ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/openedge_ls.lua:4](../lua/lspconfig/configs/openedge_ls.lua#L4) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/openedge_ls.lua:4](../lua/lspconfig/configs/openedge_ls.lua#L4) ------------------------------------------------------------------------------ @@ -7190,7 +6525,7 @@ vim.cmd [[ autocmd BufRead,BufNewFile *.scad set filetype=openscad ]] or by installing a filetype plugin such as https://github.com/sirtaj/vim-openscad Snippet to enable the language server: >lua - require'lspconfig'.openscad_ls.setup{} + vim.lsp.enable('openscad_ls') Default config: @@ -7202,8 +6537,10 @@ Default config: ```lua { "openscad" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/openscad_ls.lua:2](../lua/lspconfig/configs/openscad_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -7219,7 +6556,7 @@ cargo install openscad-lsp ``` Snippet to enable the language server: >lua - require'lspconfig'.openscad_lsp.setup{} + vim.lsp.enable('openscad_lsp') Default config: @@ -7231,44 +6568,10 @@ Default config: ```lua { "openscad" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/openscad_lsp.lua:2](../lua/lspconfig/configs/openscad_lsp.lua#L2) -- `single_file_support` : `true` - - ------------------------------------------------------------------------------- -oxlint - -https://oxc.rs - -A collection of JavaScript tools written in Rust. - -```sh -npm install [-g] oxlint -``` - -Snippet to enable the language server: >lua - require'lspconfig'.oxlint.setup{} - - -Default config: -- `cmd` : - ```lua - { "oxc_language_server" } - ``` -- `commands` : +- `root_markers` : ```lua - { - OxcFixAll = { <function 1>, - description = "Apply fixes to current buffer using oxlint (--fix)" - } - } + { ".git" } ``` -- `filetypes` : - ```lua - { "astro", "javascript", "javascriptreact", "svelte", "typescript", "typescript.tsx", "typescriptreact", "vue" } - ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/oxlint.lua:4](../lua/lspconfig/configs/oxlint.lua#L4) -- `single_file_support` : `false` ------------------------------------------------------------------------------ @@ -7279,7 +6582,7 @@ https://github.com/kadena-io/pact-lsp The Pact language server Snippet to enable the language server: >lua - require'lspconfig'.pact_ls.setup{} + vim.lsp.enable('pact_ls') Default config: @@ -7291,8 +6594,10 @@ Default config: ```lua { "pact" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/pact_ls.lua:2](../lua/lspconfig/configs/pact_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -7314,7 +6619,7 @@ export FPCTARGETCPU='x86_64' # Target CPU for cross compiling. ``` Snippet to enable the language server: >lua - require'lspconfig'.pasls.setup{} + vim.lsp.enable('pasls') Default config: @@ -7326,8 +6631,7 @@ Default config: ```lua { "pascal" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/pasls.lua:4](../lua/lspconfig/configs/pasls.lua#L4) -- `single_file_support` : `true` +- `root_dir` source (use "gF" to open): [../lsp/pasls.lua:19](../lsp/pasls.lua#L19) ------------------------------------------------------------------------------ @@ -7345,7 +6649,7 @@ cargo install --git https://git.sr.ht/~rrc/pbls pbls is a Language Server for protobuf Snippet to enable the language server: >lua - require'lspconfig'.pbls.setup{} + vim.lsp.enable('pbls') Default config: @@ -7357,7 +6661,10 @@ Default config: ```lua { "proto" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/pbls.lua:4](../lua/lspconfig/configs/pbls.lua#L4) +- `root_markers` : + ```lua + { ".pbls.toml", ".git" } + ``` ------------------------------------------------------------------------------ @@ -7370,7 +6677,7 @@ https://github.com/richterger/Perl-LanguageServer/tree/master/clients/vscode/per To use the language server, ensure that you have Perl::LanguageServer installed and perl command is on your path. Snippet to enable the language server: >lua - require'lspconfig'.perlls.setup{} + vim.lsp.enable('perlls') Default config: @@ -7382,7 +6689,10 @@ Default config: ```lua { "perl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/perlls.lua:2](../lua/lspconfig/configs/perlls.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua { @@ -7394,7 +6704,6 @@ Default config: } } ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -7421,7 +6730,7 @@ The `contributes.configuration.properties` section of `perlnavigator`'s `package settings have a reasonable default, but, at minimum, you may want to point `perlnavigator` at your `perltidy` and `perlcritic` configurations. Snippet to enable the language server: >lua - require'lspconfig'.perlnavigator.setup{} + vim.lsp.enable('perlnavigator') Default config: @@ -7433,8 +6742,10 @@ Default config: ```lua { "perl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/perlnavigator.lua:2](../lua/lspconfig/configs/perlnavigator.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -7448,7 +6759,7 @@ https://metacpan.org/pod/PLS To use the language server, ensure that you have PLS installed and that it is in your path Snippet to enable the language server: >lua - require'lspconfig'.perlpls.setup{} + vim.lsp.enable('perlpls') Default config: @@ -7460,7 +6771,10 @@ Default config: ```lua { "perl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/perlpls.lua:2](../lua/lspconfig/configs/perlpls.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua { @@ -7474,7 +6788,6 @@ Default config: } } ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -7485,7 +6798,7 @@ https://github.com/pest-parser/pest-ide-tools Language server for pest grammars. Snippet to enable the language server: >lua - require'lspconfig'.pest_ls.setup{} + vim.lsp.enable('pest_ls') Default config: @@ -7497,8 +6810,10 @@ Default config: ```lua { "pest" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/pest_ls.lua:2](../lua/lspconfig/configs/pest_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -7509,7 +6824,7 @@ https://github.com/phan/phan Installation: https://github.com/phan/phan#getting-started Snippet to enable the language server: >lua - require'lspconfig'.phan.setup{} + vim.lsp.enable('phan') Default config: @@ -7521,8 +6836,7 @@ Default config: ```lua { "php" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/phan.lua:17](../lua/lspconfig/configs/phan.lua#L17) -- `single_file_support` : `true` +- `root_dir` source (use "gF" to open): [../lsp/phan.lua:21](../lsp/phan.lua#L21) ------------------------------------------------------------------------------ @@ -7533,7 +6847,7 @@ https://github.com/phpactor/phpactor Installation: https://phpactor.readthedocs.io/en/master/usage/standalone.html#global-installation Snippet to enable the language server: >lua - require'lspconfig'.phpactor.setup{} + vim.lsp.enable('phpactor') Default config: @@ -7545,7 +6859,7 @@ Default config: ```lua { "php" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/phpactor.lua:4](../lua/lspconfig/configs/phpactor.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/phpactor.lua:8](../lsp/phpactor.lua#L8) ------------------------------------------------------------------------------ @@ -7556,7 +6870,7 @@ https://github.com/japhib/pico8-ls Full language support for the PICO-8 dialect of Lua. Snippet to enable the language server: >lua - require'lspconfig'.pico8_ls.setup{} + vim.lsp.enable('pico8_ls') Default config: @@ -7568,7 +6882,7 @@ Default config: ```lua { "p8" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/pico8_ls.lua:4](../lua/lspconfig/configs/pico8_ls.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/pico8_ls.lua:8](../lsp/pico8_ls.lua#L8) - `settings` : ```lua {} @@ -7583,7 +6897,7 @@ https://github.com/Freed-Wu/pkgbuild-language-server Language server for ArchLinux/Windows Msys2's PKGBUILD. Snippet to enable the language server: >lua - require'lspconfig'.pkgbuild_language_server.setup{} + vim.lsp.enable('pkgbuild_language_server') Default config: @@ -7595,7 +6909,10 @@ Default config: ```lua { "PKGBUILD" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/pkgbuild_language_server.lua:2](../lua/lspconfig/configs/pkgbuild_language_server.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -7608,7 +6925,7 @@ High-performance extensible build system for reproducible multi-language builds. The `plz` binary will automatically install the LSP for you on first run Snippet to enable the language server: >lua - require'lspconfig'.please.setup{} + vim.lsp.enable('please') Default config: @@ -7620,8 +6937,10 @@ Default config: ```lua { "bzl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/please.lua:4](../lua/lspconfig/configs/please.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".plzconfig" } + ``` ------------------------------------------------------------------------------ @@ -7632,7 +6951,7 @@ https://github.com/huderlem/poryscript-pls Language server for poryscript (a high level scripting language for GBA-era Pokémon decompilation projects) Snippet to enable the language server: >lua - require'lspconfig'.poryscript_pls.setup{} + vim.lsp.enable('poryscript_pls') Default config: @@ -7644,8 +6963,10 @@ Default config: ```lua { "pory" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/poryscript_pls.lua:2](../lua/lspconfig/configs/poryscript_pls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -7656,7 +6977,7 @@ https://pgtools.dev A collection of language tools and a Language Server Protocol (LSP) implementation for Postgres, focusing on developer experience and reliable SQL tooling. Snippet to enable the language server: >lua - require'lspconfig'.postgres_lsp.setup{} + vim.lsp.enable('postgres_lsp') Default config: @@ -7668,66 +6989,10 @@ Default config: ```lua { "sql" } ``` -- `single_file_support` : `true` - - ------------------------------------------------------------------------------- -powershell_es - -https://github.com/PowerShell/PowerShellEditorServices - -Language server for PowerShell. - -To install, download and extract PowerShellEditorServices.zip -from the [releases](https://github.com/PowerShell/PowerShellEditorServices/releases). -To configure the language server, set the property `bundle_path` to the root -of the extracted PowerShellEditorServices.zip. - -The default configuration doesn't set `cmd` unless `bundle_path` is specified. - -```lua -require'lspconfig'.powershell_es.setup{ - bundle_path = 'c:/w/PowerShellEditorServices', -} -``` - -By default the languageserver is started in `pwsh` (PowerShell Core). This can be changed by specifying `shell`. - -```lua -require'lspconfig'.powershell_es.setup{ - bundle_path = 'c:/w/PowerShellEditorServices', - shell = 'powershell.exe', -} -``` - -Note that the execution policy needs to be set to `Unrestricted` for the languageserver run under PowerShell - -If necessary, specific `cmd` can be defined instead of `bundle_path`. -See [PowerShellEditorServices](https://github.com/PowerShell/PowerShellEditorServices#stdio) -to learn more. - -```lua -require'lspconfig'.powershell_es.setup{ - cmd = {'pwsh', '-NoLogo', '-NoProfile', '-Command', "c:/PSES/Start-EditorServices.ps1 ..."} -} -``` - -Snippet to enable the language server: >lua - require'lspconfig'.powershell_es.setup{} - - -Default config: -- `filetypes` : - ```lua - { "ps1" } - ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/powershell_es.lua:14](../lua/lspconfig/configs/powershell_es.lua#L14) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/powershell_es.lua:14](../lua/lspconfig/configs/powershell_es.lua#L14) -- `shell` : +- `root_markers` : ```lua - "pwsh" + { "postgrestools.jsonc" } ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -7735,13 +7000,13 @@ prismals Language Server for the Prisma JavaScript and TypeScript ORM -`@prisma/language-server` can be installed via npm -```sh -npm install -g @prisma/language-server -``` + `@prisma/language-server` can be installed via npm + ```sh + npm install -g @prisma/language-server + ``` Snippet to enable the language server: >lua - require'lspconfig'.prismals.setup{} + vim.lsp.enable('prismals') Default config: @@ -7753,7 +7018,10 @@ Default config: ```lua { "prisma" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/prismals.lua:4](../lua/lspconfig/configs/prismals.lua#L4) +- `root_markers` : + ```lua + { ".git", "package.json" } + ``` - `settings` : ```lua { @@ -7769,10 +7037,10 @@ prolog_ls https://github.com/jamesnvc/lsp_server - Language Server Protocol server for SWI-Prolog +Language Server Protocol server for SWI-Prolog Snippet to enable the language server: >lua - require'lspconfig'.prolog_ls.setup{} + vim.lsp.enable('prolog_ls') Default config: @@ -7784,8 +7052,10 @@ Default config: ```lua { "prolog" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/prolog_ls.lua:4](../lua/lspconfig/configs/prolog_ls.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "pack.pl" } + ``` ------------------------------------------------------------------------------ @@ -7798,7 +7068,7 @@ An experimental LSP for Markdown. Please see the manual installation instructions: https://github.com/kitten/prosemd-lsp#manual-installation Snippet to enable the language server: >lua - require'lspconfig'.prosemd_lsp.setup{} + vim.lsp.enable('prosemd_lsp') Default config: @@ -7810,8 +7080,10 @@ Default config: ```lua { "markdown" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/prosemd_lsp.lua:2](../lua/lspconfig/configs/prosemd_lsp.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -7827,7 +7099,7 @@ cargo install protols A Language Server for proto3 files. It uses tree-sitter and runs in single file mode. Snippet to enable the language server: >lua - require'lspconfig'.protols.setup{} + vim.lsp.enable('protols') Default config: @@ -7839,8 +7111,10 @@ Default config: ```lua { "proto" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/protols.lua:2](../lua/lspconfig/configs/protols.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -7854,7 +7128,7 @@ composer global require vimeo/psalm ``` Snippet to enable the language server: >lua - require'lspconfig'.psalm.setup{} + vim.lsp.enable('psalm') Default config: @@ -7866,7 +7140,10 @@ Default config: ```lua { "php" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/psalm.lua:4](../lua/lspconfig/configs/psalm.lua#L4) +- `root_markers` : + ```lua + { "psalm.xml", "psalm.xml.dist" } + ``` ------------------------------------------------------------------------------ @@ -7879,7 +7156,7 @@ An implementation of the Language Protocol Server for [Pug.js](http://pugjs.org) PugLSP can be installed via `go get github.com/opa-oz/pug-lsp`, or manually downloaded from [releases page](https://github.com/opa-oz/pug-lsp/releases) Snippet to enable the language server: >lua - require'lspconfig'.pug.setup{} + vim.lsp.enable('pug') Default config: @@ -7891,7 +7168,10 @@ Default config: ```lua { "pug" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/pug.lua:2](../lua/lspconfig/configs/pug.lua#L2) +- `root_markers` : + ```lua + { "package.json" } + ``` ------------------------------------------------------------------------------ @@ -7913,7 +7193,7 @@ Installation: - Ensure you can run `puppet-languageserver` from outside the editor-services directory. Snippet to enable the language server: >lua - require'lspconfig'.puppet.setup{} + vim.lsp.enable('puppet') Default config: @@ -7925,8 +7205,10 @@ Default config: ```lua { "puppet" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/puppet.lua:11](../lua/lspconfig/configs/puppet.lua#L11) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "manifests", ".puppet-lint.rc", "hiera.yaml", ".git" } + ``` ------------------------------------------------------------------------------ @@ -7940,7 +7222,7 @@ The `purescript-language-server` can be added to your project and `$PATH` via * Nix under the `nodePackages` and `nodePackages_latest` package sets Snippet to enable the language server: >lua - require'lspconfig'.purescriptls.setup{} + vim.lsp.enable('purescriptls') Default config: @@ -7952,7 +7234,10 @@ Default config: ```lua { "purescript" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/purescriptls.lua:4](../lua/lspconfig/configs/purescriptls.lua#L4) +- `root_markers` : + ```lua + { "bower.json", "flake.nix", "psc-package.json", "shell.nix", "spago.dhall", "spago.yaml" } + ``` ------------------------------------------------------------------------------ @@ -7965,10 +7250,10 @@ A Python 3.6+ implementation of the Language Server Protocol. See the [project's README](https://github.com/python-lsp/python-lsp-server) for installation instructions. Configuration options are documented [here](https://github.com/python-lsp/python-lsp-server/blob/develop/CONFIGURATION.md). -In order to configure an option, it must be translated to a nested Lua table and included in the `settings` argument to the `setup{}` function. +In order to configure an option, it must be translated to a nested Lua table and included in the `settings` argument to the `config('pylsp', {})` function. For example, in order to set the `pylsp.plugins.pycodestyle.ignore` option: ```lua -require'lspconfig'.pylsp.setup{ +vim.lsp.config('pylsp', { settings = { pylsp = { plugins = { @@ -7979,13 +7264,13 @@ require'lspconfig'.pylsp.setup{ } } } -} +}) ``` Note: This is a community fork of `pyls`. Snippet to enable the language server: >lua - require'lspconfig'.pylsp.setup{} + vim.lsp.enable('pylsp') Default config: @@ -7997,8 +7282,10 @@ Default config: ```lua { "python" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/pylsp.lua:4](../lua/lspconfig/configs/pylsp.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "pyproject.toml", "setup.py", "setup.cfg", "requirements.txt", "Pipfile", ".git" } + ``` ------------------------------------------------------------------------------ @@ -8006,10 +7293,10 @@ pylyzer https://github.com/mtshiba/pylyzer - `pylyzer`, a fast static code analyzer & language server for Python. +`pylyzer`, a fast static code analyzer & language server for Python. Snippet to enable the language server: >lua - require'lspconfig'.pylyzer.setup{} + vim.lsp.enable('pylyzer') Default config: @@ -8021,7 +7308,10 @@ Default config: ```lua { "python" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/pylyzer.lua:4](../lua/lspconfig/configs/pylyzer.lua#L4) +- `root_markers` : + ```lua + { "setup.py", "tox.ini", "requirements.txt", "Pipfile", "pyproject.toml", ".git" } + ``` - `settings` : ```lua { @@ -8033,7 +7323,6 @@ Default config: } } ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -8049,7 +7338,7 @@ which are triggered on save. Do not report issues for missing features in `pyre` to `lspconfig`. Snippet to enable the language server: >lua - require'lspconfig'.pyre.setup{} + vim.lsp.enable('pyre') Default config: @@ -8061,7 +7350,10 @@ Default config: ```lua { "python" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/pyre.lua:4](../lua/lspconfig/configs/pyre.lua#L4) +- `root_markers` : + ```lua + { ".pyre_configuration" } + ``` ------------------------------------------------------------------------------ @@ -8072,12 +7364,8 @@ https://github.com/microsoft/pyright `pyright`, a static type checker and language server for python Snippet to enable the language server: >lua - require'lspconfig'.pyright.setup{} - + vim.lsp.enable('pyright') -Commands: -- PyrightOrganizeImports: Organize Imports -- PyrightSetPythonPath: Reconfigure pyright with the provided python path Default config: - `cmd` : @@ -8088,7 +7376,11 @@ Default config: ```lua { "python" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/pyright.lua:44](../lua/lspconfig/configs/pyright.lua#L44) +- `on_attach` source (use "gF" to open): [../lsp/pyright.lua:36](../lsp/pyright.lua#L36) +- `root_markers` : + ```lua + { "pyproject.toml", "setup.py", "setup.cfg", "requirements.txt", "Pipfile", "pyrightconfig.json", ".git" } + ``` - `settings` : ```lua { @@ -8101,7 +7393,6 @@ Default config: } } ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -8114,7 +7405,7 @@ https://doc.qt.io/qt-6/qtqml-tooling-qmlls.html Source in the [QtDeclarative repository](https://code.qt.io/cgit/qt/qtdeclarative.git/) Snippet to enable the language server: >lua - require'lspconfig'.qmlls.setup{} + vim.lsp.enable('qmlls') Default config: @@ -8126,8 +7417,10 @@ Default config: ```lua { "qml", "qmljs" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/qmlls.lua:2](../lua/lspconfig/configs/qmlls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -8140,7 +7433,7 @@ quick-lint-js finds bugs in JavaScript programs. See installation [instructions](https://quick-lint-js.com/install/) Snippet to enable the language server: >lua - require'lspconfig'.quick_lint_js.setup{} + vim.lsp.enable('quick_lint_js') Default config: @@ -8152,25 +7445,27 @@ Default config: ```lua { "javascript", "typescript" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/quick_lint_js.lua:4](../lua/lspconfig/configs/quick_lint_js.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "package.json", "jsconfig.json", ".git" } + ``` ------------------------------------------------------------------------------ r_language_server [languageserver](https://github.com/REditorSupport/languageserver) is an -implementation of the Microsoft's Language Server Protocol for the R -language. + implementation of the Microsoft's Language Server Protocol for the R + language. -It is released on CRAN and can be easily installed by + It is released on CRAN and can be easily installed by -```r -install.packages("languageserver") -``` + ```r + install.packages("languageserver") + ``` Snippet to enable the language server: >lua - require'lspconfig'.r_language_server.setup{} + vim.lsp.enable('r_language_server') Default config: @@ -8182,11 +7477,7 @@ Default config: ```lua { "r", "rmd", "quarto" } ``` -- `log_level` : - ```lua - 2 - ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/r_language_server.lua:2](../lua/lspconfig/configs/r_language_server.lua#L2) +- `root_dir` source (use "gF" to open): [../lsp/r_language_server.lua:12](../lsp/r_language_server.lua#L12) ------------------------------------------------------------------------------ @@ -8194,14 +7485,14 @@ racket_langserver [https://github.com/jeapostrophe/racket-langserver](https://github.com/jeapostrophe/racket-langserver) -The Racket language server. This project seeks to use -[DrRacket](https://github.com/racket/drracket)'s public API to provide -functionality that mimics DrRacket's code tools as closely as possible. + The Racket language server. This project seeks to use + [DrRacket](https://github.com/racket/drracket)'s public API to provide + functionality that mimics DrRacket's code tools as closely as possible. -Install via `raco`: `raco pkg install racket-langserver` + Install via `raco`: `raco pkg install racket-langserver` Snippet to enable the language server: >lua - require'lspconfig'.racket_langserver.setup{} + vim.lsp.enable('racket_langserver') Default config: @@ -8213,8 +7504,10 @@ Default config: ```lua { "racket", "scheme" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/racket_langserver.lua:2](../lua/lspconfig/configs/racket_langserver.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -8241,7 +7534,7 @@ The `contributes.configuration.properties` section of `raku_navigator`'s `packag settings have a reasonable default, but, at minimum, you may want to point `raku_navigator` at your `raku_tidy` and `raku_critic` configurations. Snippet to enable the language server: >lua - require'lspconfig'.raku_navigator.setup{} + vim.lsp.enable('raku_navigator') Default config: @@ -8253,8 +7546,10 @@ Default config: ```lua { "raku" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/raku_navigator.lua:2](../lua/lspconfig/configs/raku_navigator.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -8262,10 +7557,10 @@ reason_ls Reason language server -You can install reason language server from [reason-language-server](https://github.com/jaredly/reason-language-server) repository. + You can install reason language server from [reason-language-server](https://github.com/jaredly/reason-language-server) repository. Snippet to enable the language server: >lua - require'lspconfig'.reason_ls.setup{} + vim.lsp.enable('reason_ls') Default config: @@ -8277,7 +7572,10 @@ Default config: ```lua { "reason" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/reason_ls.lua:4](../lua/lspconfig/configs/reason_ls.lua#L4) +- `root_markers` : + ```lua + { "bsconfig.json", ".git" } + ``` ------------------------------------------------------------------------------ @@ -8293,7 +7591,7 @@ go install github.com/StyraInc/regal@latest ``` Snippet to enable the language server: >lua - require'lspconfig'.regal.setup{} + vim.lsp.enable('regal') Default config: @@ -8305,8 +7603,7 @@ Default config: ```lua { "rego" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/regal.lua:4](../lua/lspconfig/configs/regal.lua#L4) -- `single_file_support` : `true` +- `root_dir` source (use "gF" to open): [../lsp/regal.lua:13](../lsp/regal.lua#L13) ------------------------------------------------------------------------------ @@ -8322,7 +7619,7 @@ go install github.com/kitagry/regols@latest ``` Snippet to enable the language server: >lua - require'lspconfig'.regols.setup{} + vim.lsp.enable('regols') Default config: @@ -8334,63 +7631,7 @@ Default config: ```lua { "rego" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/regols.lua:4](../lua/lspconfig/configs/regols.lua#L4) -- `single_file_support` : `true` - - ------------------------------------------------------------------------------- -relay_lsp - -https://github.com/facebook/relay - `Relay` is a JavaScript framework for building data-driven React applications - - Setup: - - - Make sure you have a Relay config file somewhere in your project. - - We support standard config file formats (`.yml`, `.js`, `.json`), and the the `relay` field in your `package.json` - - Make sure you have the `relay-compiler` installed in your project. The bare minimum is v13. - - Make sure you are able to run the `relay-compiler` command from the command line. If `yarn relay-compiler` works, it's very likely that the LSP will work. - - Remove / disable any conflicting GraphQL LSPs you have installed. - - Relay LSP is a part of the Relay Compiler binary and available when adding `relay-compiler` to your project's devDependencies. - - ```lua - require'lspconfig'.relay_lsp.setup { - -- (default: false) Whether or not we should automatically start - -- the Relay Compiler in watch mode when you open a project - auto_start_compiler = false, - - - -- (default: null) Path to a relay config relative to the - -- `root_dir`. Without this, the compiler will search for your - -- config. This is helpful if your relay project is in a nested - -- directory. - path_to_config = nil, - } - ``` - -Snippet to enable the language server: >lua - require'lspconfig'.relay_lsp.setup{} - - -Default config: -- `auto_start_compiler` : `false` -- `cmd` : - ```lua - { "relay-compiler", "lsp" } - ``` -- `filetypes` : - ```lua - { "javascript", "javascriptreact", "javascript.jsx", "typescript", "typescriptreact", "typescript.tsx" } - ``` -- `handlers` : - ```lua - { - ["window/showStatus"] = <function 1> - } - ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/relay_lsp.lua:5](../lua/lspconfig/configs/relay_lsp.lua#L5) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/relay_lsp.lua:5](../lua/lspconfig/configs/relay_lsp.lua#L5) +- `root_dir` source (use "gF" to open): [../lsp/regols.lua:13](../lsp/regols.lua#L13) ------------------------------------------------------------------------------ @@ -8426,7 +7667,7 @@ npm install remark-preset-lint-recommended ``` Snippet to enable the language server: >lua - require'lspconfig'.remark_ls.setup{} + vim.lsp.enable('remark_ls') Default config: @@ -8438,8 +7679,10 @@ Default config: ```lua { "markdown" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/remark_ls.lua:4](../lua/lspconfig/configs/remark_ls.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".remarkrc", ".remarkrc.json", ".remarkrc.js", ".remarkrc.cjs", ".remarkrc.mjs", ".remarkrc.yml", ".remarkrc.yaml", ".remarkignore" } + ``` ------------------------------------------------------------------------------ @@ -8457,19 +7700,19 @@ for init_options supported. For example, in order to disable the `inlayHints` option: ```lua -require'lspconfig'.pylsp.setup{ +vim.lsp.config('rescriptls', { settings = { rescript = { settings = { inlayHints = { enable = false }, }, }, - } + }) } ``` Snippet to enable the language server: >lua - require'lspconfig'.rescriptls.setup{} + vim.lsp.enable('rescriptls') Default config: @@ -8503,7 +7746,10 @@ Default config: } } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/rescriptls.lua:4](../lua/lspconfig/configs/rescriptls.lua#L4) +- `root_markers` : + ```lua + { "bsconfig.json", "rescript.json", ".git" } + ``` - `settings` : ```lua {} @@ -8523,7 +7769,7 @@ All settings listed on the rls configuration section of the readme must be set under settings.rust as follows: ```lua -nvim_lsp.rls.setup { +vim.lsp.config('rls', { settings = { rust = { unstable_features = true, @@ -8531,7 +7777,7 @@ nvim_lsp.rls.setup { all_features = true, }, }, -} +}) ``` If you want to use rls for a particular build, eg nightly, set cmd as follows: @@ -8541,7 +7787,7 @@ cmd = {"rustup", "run", "nightly", "rls"} ``` Snippet to enable the language server: >lua - require'lspconfig'.rls.setup{} + vim.lsp.enable('rls') Default config: @@ -8553,7 +7799,10 @@ Default config: ```lua { "rust" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/rls.lua:4](../lua/lspconfig/configs/rls.lua#L4) +- `root_markers` : + ```lua + { "Cargo.toml" } + ``` ------------------------------------------------------------------------------ @@ -8568,7 +7817,7 @@ To install manually, run `cargo install rnix-lsp`. If you are using nix, rnix-ls This server accepts configuration via the `settings` key. Snippet to enable the language server: >lua - require'lspconfig'.rnix.setup{} + vim.lsp.enable('rnix') Default config: @@ -8584,7 +7833,7 @@ Default config: ```lua {} ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/rnix.lua:2](../lua/lspconfig/configs/rnix.lua#L2) +- `root_dir` source (use "gF" to open): [../lsp/rnix.lua:10](../lsp/rnix.lua#L10) - `settings` : ```lua {} @@ -8599,7 +7848,7 @@ https://robotcode.io RobotCode - Language Server Protocol implementation for Robot Framework. Snippet to enable the language server: >lua - require'lspconfig'.robotcode.setup{} + vim.lsp.enable('robotcode') Default config: @@ -8611,9 +7860,11 @@ Default config: ```lua { "robot", "resource" } ``` -- `get_language_id` source (use "gF" to visit): [../lua/lspconfig/configs/robotcode.lua:4](../lua/lspconfig/configs/robotcode.lua#L4) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/robotcode.lua:4](../lua/lspconfig/configs/robotcode.lua#L4) -- `single_file_support` : `true` +- `get_language_id` source (use "gF" to open): [../lsp/robotcode.lua:6](../lsp/robotcode.lua#L6) +- `root_markers` : + ```lua + { "robot.toml", "pyproject.toml", "Pipfile", ".git" } + ``` ------------------------------------------------------------------------------ @@ -8624,7 +7875,7 @@ https://github.com/robocorp/robotframework-lsp Language Server Protocol implementation for Robot Framework. Snippet to enable the language server: >lua - require'lspconfig'.robotframework_ls.setup{} + vim.lsp.enable('robotframework_ls') Default config: @@ -8636,7 +7887,10 @@ Default config: ```lua { "robot" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/robotframework_ls.lua:4](../lua/lspconfig/configs/robotframework_ls.lua#L4) +- `root_markers` : + ```lua + { "robotidy.toml", "pyproject.toml", "conda.yaml", "robot.yaml", ".git" } + ``` ------------------------------------------------------------------------------ @@ -8648,7 +7902,7 @@ The built-in language server for the Roc programming language. [Installation](https://github.com/roc-lang/roc/tree/main/crates/language_server#installing) Snippet to enable the language server: >lua - require'lspconfig'.roc_ls.setup{} + vim.lsp.enable('roc_ls') Default config: @@ -8660,8 +7914,10 @@ Default config: ```lua { "roc" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/roc_ls.lua:2](../lua/lspconfig/configs/roc_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -8678,7 +7934,7 @@ npm install [-g] rome ``` Snippet to enable the language server: >lua - require'lspconfig'.rome.setup{} + vim.lsp.enable('rome') Default config: @@ -8690,8 +7946,10 @@ Default config: ```lua { "javascript", "javascriptreact", "json", "typescript", "typescript.tsx", "typescriptreact" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/rome.lua:2](../lua/lspconfig/configs/rome.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "package.json", "node_modules", ".git" } + ``` ------------------------------------------------------------------------------ @@ -8702,7 +7960,7 @@ https://github.com/dcermak/rpm-spec-language-server Language server protocol (LSP) support for RPM Spec files. Snippet to enable the language server: >lua - require'lspconfig'.rpmspec.setup{} + vim.lsp.enable('rpmspec') Default config: @@ -8714,12 +7972,14 @@ Default config: ```lua { "spec" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/rpmspec.lua:2](../lua/lspconfig/configs/rpmspec.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua {} ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -8728,7 +7988,7 @@ rubocop https://github.com/rubocop/rubocop Snippet to enable the language server: >lua - require'lspconfig'.rubocop.setup{} + vim.lsp.enable('rubocop') Default config: @@ -8740,7 +8000,10 @@ Default config: ```lua { "ruby" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/rubocop.lua:4](../lua/lspconfig/configs/rubocop.lua#L4) +- `root_markers` : + ```lua + { "Gemfile", ".git" } + ``` ------------------------------------------------------------------------------ @@ -8759,7 +8022,7 @@ gem install ruby-lsp ``` Snippet to enable the language server: >lua - require'lspconfig'.ruby_lsp.setup{} + vim.lsp.enable('ruby_lsp') Default config: @@ -8777,8 +8040,10 @@ Default config: formatter = "auto" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ruby_lsp.lua:4](../lua/lspconfig/configs/ruby_lsp.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "Gemfile", ".git" } + ``` ------------------------------------------------------------------------------ @@ -8799,7 +8064,7 @@ This is the new built-in language server written in Rust. It supports the same f Server settings can be provided via: ```lua -require('lspconfig').ruff.setup({ +vim.lsp.config('ruff', { init_options = { settings = { -- Server settings should go here @@ -8811,7 +8076,7 @@ require('lspconfig').ruff.setup({ Refer to the [documentation](https://docs.astral.sh/ruff/editors/) for more details. Snippet to enable the language server: >lua - require'lspconfig'.ruff.setup{} + vim.lsp.enable('ruff') Default config: @@ -8823,12 +8088,14 @@ Default config: ```lua { "python" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ruff.lua:4](../lua/lspconfig/configs/ruff.lua#L4) +- `root_markers` : + ```lua + { "pyproject.toml", "ruff.toml", ".ruff.toml", ".git" } + ``` - `settings` : ```lua {} ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -8845,18 +8112,18 @@ pip install ruff-lsp Extra CLI arguments for `ruff` can be provided via ```lua -require'lspconfig'.ruff_lsp.setup{ +vim.lsp.config('ruff_lsp', { init_options = { settings = { -- Any extra CLI arguments for `ruff` go here. args = {}, } } -} +}) ``` Snippet to enable the language server: >lua - require'lspconfig'.ruff_lsp.setup{} + vim.lsp.enable('ruff_lsp') Default config: @@ -8868,12 +8135,14 @@ Default config: ```lua { "python" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ruff_lsp.lua:4](../lua/lspconfig/configs/ruff_lsp.lua#L4) +- `root_markers` : + ```lua + { "pyproject.toml", "ruff.toml", ".git" } + ``` - `settings` : ```lua {} ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -8885,7 +8154,7 @@ A language server for the [Rune](https://rune-rs.github.io/) Language, an embeddable dynamic programming language for Rust Snippet to enable the language server: >lua - require'lspconfig'.rune_languageserver.setup{} + vim.lsp.enable('rune_languageserver') Default config: @@ -8897,8 +8166,10 @@ Default config: ```lua { "rune" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/rune_languageserver.lua:2](../lua/lspconfig/configs/rune_languageserver.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -8911,7 +8182,7 @@ rust-analyzer (aka rls 2.0), a language server for Rust See [docs](https://rust-analyzer.github.io/book/configuration.html) for extra settings. The settings can be used like this: ```lua -require'lspconfig'.rust_analyzer.setup{ +vim.lsp.config('rust_analyzer', { settings = { ['rust-analyzer'] = { diagnostics = { @@ -8919,21 +8190,18 @@ require'lspconfig'.rust_analyzer.setup{ } } } -} +}) ``` Note: do not set `init_options` for this LS config, it will be automatically populated by the contents of settings["rust-analyzer"] per https://github.com/rust-lang/rust-analyzer/blob/eb5da56d839ae0a9e9f50774fa3eb78eb0964550/docs/dev/lsp-extensions.md?plain=1#L26. Snippet to enable the language server: >lua - require'lspconfig'.rust_analyzer.setup{} + vim.lsp.enable('rust_analyzer') -Commands: -- CargoReload: Reload current cargo workspace - Default config: -- `before_init` source (use "gF" to visit): [../lua/lspconfig/configs/rust_analyzer.lua:36](../lua/lspconfig/configs/rust_analyzer.lua#L36) +- `before_init` source (use "gF" to open): [../lsp/rust_analyzer.lua:56](../lsp/rust_analyzer.lua#L56) - `capabilities` : ```lua { @@ -8950,23 +8218,23 @@ Default config: ```lua { "rust" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/rust_analyzer.lua:36](../lua/lspconfig/configs/rust_analyzer.lua#L36) -- `single_file_support` : `true` +- `on_attach` source (use "gF" to open): [../lsp/rust_analyzer.lua:56](../lsp/rust_analyzer.lua#L56) +- `root_dir` source (use "gF" to open): [../lsp/rust_analyzer.lua:56](../lsp/rust_analyzer.lua#L56) ------------------------------------------------------------------------------ salt_ls Language server for Salt configuration files. -https://github.com/dcermak/salt-lsp + https://github.com/dcermak/salt-lsp -The language server can be installed with `pip`: -```sh -pip install salt-lsp -``` + The language server can be installed with `pip`: + ```sh + pip install salt-lsp + ``` Snippet to enable the language server: >lua - require'lspconfig'.salt_ls.setup{} + vim.lsp.enable('salt_ls') Default config: @@ -8978,8 +8246,10 @@ Default config: ```lua { "sls" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/salt_ls.lua:2](../lua/lspconfig/configs/salt_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -8990,7 +8260,7 @@ https://github.com/ufo5260987423/scheme-langserver And for nvim user, please add .sls to scheme file extension list. Snippet to enable the language server: >lua - require'lspconfig'.scheme_langserver.setup{} + vim.lsp.enable('scheme_langserver') Default config: @@ -9002,8 +8272,10 @@ Default config: ```lua { "scheme" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/scheme_langserver.lua:9](../lua/lspconfig/configs/scheme_langserver.lua#L9) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "Akku.manifest", ".git" } + ``` ------------------------------------------------------------------------------ @@ -9014,7 +8286,7 @@ https://github.com/crystal-lang-tools/scry Crystal language server. Snippet to enable the language server: >lua - require'lspconfig'.scry.setup{} + vim.lsp.enable('scry') Default config: @@ -9026,8 +8298,10 @@ Default config: ```lua { "crystal" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/scry.lua:4](../lua/lspconfig/configs/scry.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "shard.yml", ".git" } + ``` ------------------------------------------------------------------------------ @@ -9038,7 +8312,7 @@ https://github.com/antonk52/lua-3p-language-servers 3rd party Language Server for Selene lua linter Snippet to enable the language server: >lua - require'lspconfig'.selene3p_ls.setup{} + vim.lsp.enable('selene3p_ls') Default config: @@ -9050,7 +8324,10 @@ Default config: ```lua { "lua" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/selene3p_ls.lua:4](../lua/lspconfig/configs/selene3p_ls.lua#L4) +- `root_markers` : + ```lua + { "selene.toml" } + ``` ------------------------------------------------------------------------------ @@ -9058,11 +8335,11 @@ serve_d https://github.com/Pure-D/serve-d - `Microsoft language server protocol implementation for D using workspace-d.` - Download a binary from https://github.com/Pure-D/serve-d/releases and put it in your $PATH. +Microsoft language server protocol implementation for D using workspace-d. +Download a binary from https://github.com/Pure-D/serve-d/releases and put it in your $PATH. Snippet to enable the language server: >lua - require'lspconfig'.serve_d.setup{} + vim.lsp.enable('serve_d') Default config: @@ -9074,7 +8351,10 @@ Default config: ```lua { "d" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/serve_d.lua:4](../lua/lspconfig/configs/serve_d.lua#L4) +- `root_markers` : + ```lua + { "dub.json", "dub.sdl", ".git" } + ``` ------------------------------------------------------------------------------ @@ -9089,7 +8369,7 @@ https://shopify.dev/docs/api/shopify-cli Note: This LSP already includes Theme Check so you don't need to use the `theme_check` server configuration as well. Snippet to enable the language server: >lua - require'lspconfig'.shopify_theme_ls.setup{} + vim.lsp.enable('shopify_theme_ls') Default config: @@ -9101,7 +8381,10 @@ Default config: ```lua { "liquid" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/shopify_theme_ls.lua:11](../lua/lspconfig/configs/shopify_theme_ls.lua#L11) +- `root_markers` : + ```lua + { ".shopifyignore", ".theme-check.yml", ".theme-check.yaml", "shopify.theme.toml" } + ``` - `settings` : ```lua {} @@ -9130,7 +8413,7 @@ vim.cmd [[ autocmd BufRead,BufNewFile *.60 set filetype=sixtyfps ]] or by installing a filetype plugin such as https://github.com/RustemB/sixtyfps-vim Snippet to enable the language server: >lua - require'lspconfig'.sixtyfps.setup{} + vim.lsp.enable('sixtyfps') Default config: @@ -9142,7 +8425,6 @@ Default config: ```lua { "sixtyfps" } ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -9156,7 +8438,7 @@ by [building `slang` from source](https://github.com/shader-slang/slang/blob/mas The server can be configured by passing a "settings" object to `slangd.setup{}`: ```lua -require('lspconfig').slangd.setup{ +vim.lsp.config('slangd', { settings = { slang = { predefinedMacros = {"MY_VALUE_MACRO=1"}, @@ -9166,13 +8448,13 @@ require('lspconfig').slangd.setup{ } } } -} +}) ``` Available options are documented [here](https://github.com/shader-slang/slang-vscode-extension/tree/main?tab=readme-ov-file#configurations) or in more detail [here](https://github.com/shader-slang/slang-vscode-extension/blob/main/package.json#L70). Snippet to enable the language server: >lua - require'lspconfig'.slangd.setup{} + vim.lsp.enable('slangd') Default config: @@ -9184,8 +8466,10 @@ Default config: ```lua { "hlsl", "shaderslang" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/slangd.lua:8](../lua/lspconfig/configs/slangd.lua#L8) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -9208,7 +8492,7 @@ vim.cmd [[ autocmd BufRead,BufNewFile *.slint set filetype=slint ]] ``` Snippet to enable the language server: >lua - require'lspconfig'.slint_lsp.setup{} + vim.lsp.enable('slint_lsp') Default config: @@ -9220,8 +8504,10 @@ Default config: ```lua { "slint" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/slint_lsp.lua:2](../lua/lspconfig/configs/slint_lsp.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -9238,7 +8524,7 @@ npm i -g vscode-smarty-langserver-extracted ``` Snippet to enable the language server: >lua - require'lspconfig'.smarty_ls.setup{} + vim.lsp.enable('smarty_ls') Default config: @@ -9254,7 +8540,7 @@ Default config: ```lua {} ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/smarty_ls.lua:4](../lua/lspconfig/configs/smarty_ls.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/smarty_ls.lua:14](../lsp/smarty_ls.lua#L14) - `settings` : ```lua { @@ -9276,7 +8562,7 @@ https://github.com/awslabs/smithy-language-server `Smithy Language Server`, A Language Server Protocol implementation for the Smithy IDL Snippet to enable the language server: >lua - require'lspconfig'.smithy_ls.setup{} + vim.lsp.enable('smithy_ls') Default config: @@ -9288,8 +8574,10 @@ Default config: ```lua { "smithy" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/smithy_ls.lua:7](../lua/lspconfig/configs/smithy_ls.lua#L7) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "smithy-build.json", "build.gradle", "build.gradle.kts", ".git" } + ``` ------------------------------------------------------------------------------ @@ -9303,7 +8591,7 @@ npm install -g @snakeskin/cli ``` Snippet to enable the language server: >lua - require'lspconfig'.snakeskin_ls.setup{} + vim.lsp.enable('snakeskin_ls') Default config: @@ -9315,7 +8603,10 @@ Default config: ```lua { "ss" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/snakeskin_ls.lua:4](../lua/lspconfig/configs/snakeskin_ls.lua#L4) +- `root_markers` : + ```lua + { "package.json" } + ``` ------------------------------------------------------------------------------ @@ -9326,7 +8617,7 @@ https://github.com/snyk/snyk-ls LSP for Snyk Open Source, Snyk Infrastructure as Code, and Snyk Code. Snippet to enable the language server: >lua - require'lspconfig'.snyk_ls.setup{} + vim.lsp.enable('snyk_ls') Default config: @@ -9344,12 +8635,14 @@ Default config: activateSnykCode = "true" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/snyk_ls.lua:4](../lua/lspconfig/configs/snyk_ls.lua#L4) +- `root_markers` : + ```lua + { ".git", ".snyk" } + ``` - `settings` : ```lua {} ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -9357,17 +8650,17 @@ solang A language server for Solidity -See the [documentation](https://solang.readthedocs.io/en/latest/installing.html) for installation instructions. + See the [documentation](https://solang.readthedocs.io/en/latest/installing.html) for installation instructions. -The language server only provides the following capabilities: -* Syntax highlighting -* Diagnostics -* Hover + The language server only provides the following capabilities: + * Syntax highlighting + * Diagnostics + * Hover -There is currently no support for completion, goto definition, references, or other functionality. + There is currently no support for completion, goto definition, references, or other functionality. Snippet to enable the language server: >lua - require'lspconfig'.solang.setup{} + vim.lsp.enable('solang') Default config: @@ -9379,7 +8672,10 @@ Default config: ```lua { "solidity" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/solang.lua:2](../lua/lspconfig/configs/solang.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -9396,7 +8692,7 @@ gem install --user-install solargraph ``` Snippet to enable the language server: >lua - require'lspconfig'.solargraph.setup{} + vim.lsp.enable('solargraph') Default config: @@ -9414,7 +8710,10 @@ Default config: formatting = true } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/solargraph.lua:4](../lua/lspconfig/configs/solargraph.lua#L4) +- `root_markers` : + ```lua + { "Gemfile", ".git" } + ``` - `settings` : ```lua { @@ -9433,7 +8732,7 @@ https://docs.soliditylang.org/en/latest/installing-solidity.html solc is the native language server for the Solidity language. Snippet to enable the language server: >lua - require'lspconfig'.solc.setup{} + vim.lsp.enable('solc') Default config: @@ -9445,7 +8744,7 @@ Default config: ```lua { "solidity" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/solc.lua:4](../lua/lspconfig/configs/solc.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/solc.lua:8](../lsp/solc.lua#L8) ------------------------------------------------------------------------------ @@ -9459,8 +8758,8 @@ Make sure that solc is installed and it's the same version of the file. solc-se Solidity language server is a LSP with autocomplete, go to definition and diagnostics. -If you use brownie, use this root_dir: -root_dir = util.root_pattern('brownie-config.yaml', '.git') +If you use brownie, use this root_markers: +root_markers = { 'brownie-config.yaml', '.git' } on includePath, you can add an extra path to search for external libs, on remapping you can remap lib <> path, like: @@ -9469,10 +8768,10 @@ on includePath, you can add an extra path to search for external libs, on remapp ``` **For brownie users** -Change the root_dir to: +Change the root_markers to: ```lua -root_pattern("brownie-config.yaml", ".git") +root_markers = { 'brownie-config.yaml', '.git' } ``` The best way of using it is to have a package.json in your project folder with the packages that you will use. @@ -9485,7 +8784,7 @@ After installing with package.json, just create a `remappings.txt` with: You can omit the node_modules as well. Snippet to enable the language server: >lua - require'lspconfig'.solidity.setup{} + vim.lsp.enable('solidity') Default config: @@ -9497,7 +8796,10 @@ Default config: ```lua { "solidity" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/solidity.lua:4](../lua/lspconfig/configs/solidity.lua#L4) +- `root_markers` : + ```lua + { ".git", "package.json" } + ``` - `settings` : ```lua { @@ -9523,7 +8825,7 @@ npm install -g vscode-solidity-server `vscode-solidity-server` is a language server for the Solidity language ported from the VSCode "solidity" extension. Snippet to enable the language server: >lua - require'lspconfig'.solidity_ls.setup{} + vim.lsp.enable('solidity_ls') Default config: @@ -9535,8 +8837,10 @@ Default config: ```lua { "solidity" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/solidity_ls.lua:14](../lua/lspconfig/configs/solidity_ls.lua#L14) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "hardhat.config.js", "hardhat.config.ts", "foundry.toml", "remappings.txt", "truffle.js", "truffle-config.js", "ape-config.yaml", ".git", "package.json" } + ``` ------------------------------------------------------------------------------ @@ -9553,7 +8857,7 @@ npm install -g @nomicfoundation/solidity-language-server A language server for the Solidity programming language, built by the Nomic Foundation for the Ethereum community. Snippet to enable the language server: >lua - require'lspconfig'.solidity_ls_nomicfoundation.setup{} + vim.lsp.enable('solidity_ls_nomicfoundation') Default config: @@ -9565,8 +8869,10 @@ Default config: ```lua { "solidity" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/solidity_ls_nomicfoundation.lua:14](../lua/lspconfig/configs/solidity_ls_nomicfoundation.lua#L14) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "hardhat.config.js", "hardhat.config.ts", "foundry.toml", "remappings.txt", "truffle.js", "truffle-config.js", "ape-config.yaml", ".git", "package.json" } + ``` ------------------------------------------------------------------------------ @@ -9589,7 +8895,7 @@ The language server provides: - Suggestions and hover info for built-in Sass modules, when used with @use. Snippet to enable the language server: >lua - require'lspconfig'.somesass_ls.setup{} + vim.lsp.enable('somesass_ls') Default config: @@ -9605,7 +8911,10 @@ Default config: ```lua "somesass_ls" ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/somesass_ls.lua:4](../lua/lspconfig/configs/somesass_ls.lua#L4) +- `root_markers` : + ```lua + { ".git", ".package.json" } + ``` - `settings` : ```lua { @@ -9614,7 +8923,6 @@ Default config: } } ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -9632,7 +8940,7 @@ gem install sorbet ``` Snippet to enable the language server: >lua - require'lspconfig'.sorbet.setup{} + vim.lsp.enable('sorbet') Default config: @@ -9644,7 +8952,10 @@ Default config: ```lua { "ruby" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/sorbet.lua:4](../lua/lspconfig/configs/sorbet.lua#L4) +- `root_markers` : + ```lua + { "Gemfile", ".git" } + ``` ------------------------------------------------------------------------------ @@ -9655,7 +8966,7 @@ https://github.com/swiftlang/sourcekit-lsp Language server for Swift and C/C++/Objective-C. Snippet to enable the language server: >lua - require'lspconfig'.sourcekit.setup{} + vim.lsp.enable('sourcekit') Default config: @@ -9683,61 +8994,8 @@ Default config: ```lua { "swift", "objc", "objcpp", "c", "cpp" } ``` -- `get_language_id` source (use "gF" to visit): [../lua/lspconfig/configs/sourcekit.lua:4](../lua/lspconfig/configs/sourcekit.lua#L4) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/sourcekit.lua:4](../lua/lspconfig/configs/sourcekit.lua#L4) - - ------------------------------------------------------------------------------- -sourcery - -https://github.com/sourcery-ai/sourcery - -Refactor Python instantly using the power of AI. - -It requires the init_options param to be populated as shown below and will respond with the list of ServerCapabilities that it supports: - -```lua -require'lspconfig'.sourcery.setup { - init_options = { - --- The Sourcery token for authenticating the user. - --- This is retrieved from the Sourcery website and must be - --- provided by each user. The extension must provide a - --- configuration option for the user to provide this value. - token = <YOUR_TOKEN>, - - --- The extension's name and version as defined by the extension. - extension_version = 'vim.lsp', - - --- The editor's name and version as defined by the editor. - editor_version = 'vim', - }, -} -``` - -Alternatively, you can login to sourcery by running `sourcery login` with sourcery-cli. - -Snippet to enable the language server: >lua - require'lspconfig'.sourcery.setup{} - - -Default config: -- `cmd` : - ```lua - { "sourcery", "lsp" } - ``` -- `filetypes` : - ```lua - { "javascript", "javascriptreact", "python", "typescript", "typescriptreact" } - ``` -- `init_options` : - ```lua - { - editor_version = "vim", - extension_version = "vim.lsp" - } - ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/sourcery.lua:32](../lua/lspconfig/configs/sourcery.lua#L32) -- `single_file_support` : `true` +- `get_language_id` source (use "gF" to open): [../lsp/sourcekit.lua:8](../lsp/sourcekit.lua#L8) +- `root_dir` source (use "gF" to open): [../lsp/sourcekit.lua:8](../lsp/sourcekit.lua#L8) ------------------------------------------------------------------------------ @@ -9753,7 +9011,7 @@ npm i -g spectral-language-server See [vscode-spectral](https://github.com/stoplightio/vscode-spectral#extension-settings) for configuration options. Snippet to enable the language server: >lua - require'lspconfig'.spectral.setup{} + vim.lsp.enable('spectral') Default config: @@ -9765,7 +9023,10 @@ Default config: ```lua { "yaml", "json", "yml" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/spectral.lua:6](../lua/lspconfig/configs/spectral.lua#L6) +- `root_markers` : + ```lua + { ".spectral.yaml", ".spectral.yml", ".spectral.json", ".spectral.js" } + ``` - `settings` : ```lua { @@ -9774,7 +9035,6 @@ Default config: validateLanguages = { "yaml", "json", "yml" } } ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -9797,7 +9057,7 @@ You may also need to configure the filetype: This is automatically done by [CrystalAlpha358/vim-mcfunction](https://github.com/CrystalAlpha358/vim-mcfunction), which also provide syntax highlight. Snippet to enable the language server: >lua - require'lspconfig'.spyglassmc_language_server.setup{} + vim.lsp.enable('spyglassmc_language_server') Default config: @@ -9809,8 +9069,10 @@ Default config: ```lua { "mcfunction" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/spyglassmc_language_server.lua:4](../lua/lspconfig/configs/spyglassmc_language_server.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "pack.mcmeta" } + ``` ------------------------------------------------------------------------------ @@ -9822,7 +9084,7 @@ This LSP can be installed via `npm`. Find further instructions on manual instal <br> Snippet to enable the language server: >lua - require'lspconfig'.sqlls.setup{} + vim.lsp.enable('sqlls') Default config: @@ -9834,7 +9096,10 @@ Default config: ```lua { "sql", "mysql" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/sqlls.lua:4](../lua/lspconfig/configs/sqlls.lua#L4) +- `root_markers` : + ```lua + { ".sqllsrc.json" } + ``` - `settings` : ```lua {} @@ -9847,15 +9112,15 @@ sqls https://github.com/sqls-server/sqls ```lua -require'lspconfig'.sqls.setup{ +vim.lsp.config('sqls', { cmd = {"path/to/command", "-config", "path/to/config.yml"}; ... -} +}) ``` Sqls can be installed via `go get github.com/sqls-server/sqls`. Instructions for compiling Sqls from the source can be found at [sqls-server/sqls](https://github.com/sqls-server/sqls). Snippet to enable the language server: >lua - require'lspconfig'.sqls.setup{} + vim.lsp.enable('sqls') Default config: @@ -9867,12 +9132,14 @@ Default config: ```lua { "sql", "mysql" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/sqls.lua:4](../lua/lspconfig/configs/sqls.lua#L4) +- `root_markers` : + ```lua + { "config.yml" } + ``` - `settings` : ```lua {} ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -9883,7 +9150,7 @@ https://github.com/testdouble/standard Ruby Style Guide, with linter & automatic code fixer. Snippet to enable the language server: >lua - require'lspconfig'.standardrb.setup{} + vim.lsp.enable('standardrb') Default config: @@ -9895,7 +9162,10 @@ Default config: ```lua { "ruby" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/standardrb.lua:4](../lua/lspconfig/configs/standardrb.lua#L4) +- `root_markers` : + ```lua + { "Gemfile", ".git" } + ``` ------------------------------------------------------------------------------ @@ -9910,7 +9180,7 @@ but does not support refactorings. It can be installed with cargo: https://crates.io/crates/starlark Snippet to enable the language server: >lua - require'lspconfig'.starlark_rust.setup{} + vim.lsp.enable('starlark_rust') Default config: @@ -9922,7 +9192,10 @@ Default config: ```lua { "star", "bzl", "BUILD.bazel" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/starlark_rust.lua:2](../lua/lspconfig/configs/starlark_rust.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -9933,7 +9206,7 @@ https://github.com/withered-magic/starpls `starpls` is an LSP implementation for Starlark. Installation instructions can be found in the project's README. Snippet to enable the language server: >lua - require'lspconfig'.starpls.setup{} + vim.lsp.enable('starpls') Default config: @@ -9945,7 +9218,10 @@ Default config: ```lua { "bzl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/starpls.lua:4](../lua/lspconfig/configs/starpls.lua#L4) +- `root_markers` : + ```lua + { "WORKSPACE", "WORKSPACE.bazel", "MODULE.bazel" } + ``` ------------------------------------------------------------------------------ @@ -9956,7 +9232,7 @@ https://github.com/nerdypepper/statix lints and suggestions for the nix programming language Snippet to enable the language server: >lua - require'lspconfig'.statix.setup{} + vim.lsp.enable('statix') Default config: @@ -9968,8 +9244,10 @@ Default config: ```lua { "nix" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/statix.lua:4](../lua/lspconfig/configs/statix.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "flake.nix", ".git" } + ``` ------------------------------------------------------------------------------ @@ -9982,7 +9260,7 @@ https://github.com/soutaro/steep You need `Steepfile` to make it work. Generate it with `steep init`. Snippet to enable the language server: >lua - require'lspconfig'.steep.setup{} + vim.lsp.enable('steep') Default config: @@ -9994,7 +9272,10 @@ Default config: ```lua { "ruby", "eruby" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/steep.lua:4](../lua/lspconfig/configs/steep.lua#L4) +- `root_markers` : + ```lua + { "Steepfile", ".git" } + ``` ------------------------------------------------------------------------------ @@ -10015,7 +9296,7 @@ yarn global add stimulus-language-server ``` Snippet to enable the language server: >lua - require'lspconfig'.stimulus_ls.setup{} + vim.lsp.enable('stimulus_ls') Default config: @@ -10027,7 +9308,10 @@ Default config: ```lua { "html", "ruby", "eruby", "blade", "php" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/stimulus_ls.lua:4](../lua/lspconfig/configs/stimulus_ls.lua#L4) +- `root_markers` : + ```lua + { "Gemfile", ".git" } + ``` ------------------------------------------------------------------------------ @@ -10044,17 +9328,17 @@ npm i -g stylelint-lsp Can be configured by passing a `settings.stylelintplus` object to `stylelint_lsp.setup`: ```lua -require'lspconfig'.stylelint_lsp.setup{ +vim.lsp.config('stylelint_lsp', { settings = { stylelintplus = { -- see available options in stylelint-lsp documentation } } -} +}) ``` Snippet to enable the language server: >lua - require'lspconfig'.stylelint_lsp.setup{} + vim.lsp.enable('stylelint_lsp') Default config: @@ -10066,7 +9350,10 @@ Default config: ```lua { "astro", "css", "html", "less", "scss", "sugarss", "vue", "wxss" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/stylelint_lsp.lua:19](../lua/lspconfig/configs/stylelint_lsp.lua#L19) +- `root_markers` : + ```lua + { ".stylelintrc", ".stylelintrc.mjs", ".stylelintrc.cjs", ".stylelintrc.js", ".stylelintrc.json", ".stylelintrc.yaml", ".stylelintrc.yml", "stylelint.config.mjs", "stylelint.config.cjs", "stylelint.config.js" } + ``` - `settings` : ```lua {} @@ -10081,7 +9368,7 @@ https://github.com/antonk52/lua-3p-language-servers 3rd party Language Server for Stylua lua formatter Snippet to enable the language server: >lua - require'lspconfig'.stylua3p_ls.setup{} + vim.lsp.enable('stylua3p_ls') Default config: @@ -10093,7 +9380,10 @@ Default config: ```lua { "lua" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/stylua3p_ls.lua:4](../lua/lspconfig/configs/stylua3p_ls.lua#L4) +- `root_markers` : + ```lua + { ".stylua.toml", "stylua.toml" } + ``` ------------------------------------------------------------------------------ @@ -10110,13 +9400,13 @@ If you want to disable HTML support for another HTML LSP, add the following to your configuration: ```lua -require'lspconfig'.superhtml.setup { +vim.lsp.config('superhtml', { filetypes = { 'superhtml' } -} +}) ``` Snippet to enable the language server: >lua - require'lspconfig'.superhtml.setup{} + vim.lsp.enable('superhtml') Default config: @@ -10128,8 +9418,10 @@ Default config: ```lua { "superhtml", "html" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/superhtml.lua:2](../lua/lspconfig/configs/superhtml.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -10145,11 +9437,8 @@ npm install -g svelte-language-server ``` Snippet to enable the language server: >lua - require'lspconfig'.svelte.setup{} - + vim.lsp.enable('svelte') -Commands: -- MigrateToSvelte5: Migrate Component to Svelte 5 Syntax Default config: - `cmd` : @@ -10160,7 +9449,11 @@ Default config: ```lua { "svelte" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/svelte.lua:17](../lua/lspconfig/configs/svelte.lua#L17) +- `on_attach` source (use "gF" to open): [../lsp/svelte.lua:24](../lsp/svelte.lua#L24) +- `root_markers` : + ```lua + { "package.json", ".git" } + ``` ------------------------------------------------------------------------------ @@ -10177,12 +9470,8 @@ $ npm install -g @imc-trading/svlangserver ``` Snippet to enable the language server: >lua - require'lspconfig'.svlangserver.setup{} - + vim.lsp.enable('svlangserver') -Commands: -- SvlangserverBuildIndex: Instructs language server to rerun indexing -- SvlangserverReportHierarchy: Generates hierarchy for the given module Default config: - `cmd` : @@ -10193,7 +9482,11 @@ Default config: ```lua { "verilog", "systemverilog" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/svlangserver.lua:19](../lua/lspconfig/configs/svlangserver.lua#L19) +- `on_attach` source (use "gF" to open): [../lsp/svlangserver.lua:27](../lsp/svlangserver.lua#L27) +- `root_markers` : + ```lua + { ".svlangserver", ".git" } + ``` - `settings` : ```lua { @@ -10202,7 +9495,6 @@ Default config: } } ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -10218,7 +9510,7 @@ Language server for verilog and SystemVerilog ``` Snippet to enable the language server: >lua - require'lspconfig'.svls.setup{} + vim.lsp.enable('svls') Default config: @@ -10230,7 +9522,10 @@ Default config: ```lua { "verilog", "systemverilog" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/svls.lua:2](../lua/lspconfig/configs/svls.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -10241,7 +9536,7 @@ https://github.com/JCWasmx86/Swift-MesonLSP Meson language server written in Swift Snippet to enable the language server: >lua - require'lspconfig'.swift_mesonls.setup{} + vim.lsp.enable('swift_mesonls') Default config: @@ -10253,7 +9548,10 @@ Default config: ```lua { "meson" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/swift_mesonls.lua:4](../lua/lspconfig/configs/swift_mesonls.lua#L4) +- `root_markers` : + ```lua + { "meson.build", "meson_options.txt", "meson.options", ".git" } + ``` ------------------------------------------------------------------------------ @@ -10273,7 +9571,7 @@ gem install syntax_tree ``` Snippet to enable the language server: >lua - require'lspconfig'.syntax_tree.setup{} + vim.lsp.enable('syntax_tree') Default config: @@ -10285,7 +9583,10 @@ Default config: ```lua { "ruby" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/syntax_tree.lua:4](../lua/lspconfig/configs/syntax_tree.lua#L4) +- `root_markers` : + ```lua + { ".streerc", "Gemfile", ".git" } + ``` ------------------------------------------------------------------------------ @@ -10301,7 +9602,7 @@ pip install systemd-language-server Language Server for Systemd unit files Snippet to enable the language server: >lua - require'lspconfig'.systemd_ls.setup{} + vim.lsp.enable('systemd_ls') Default config: @@ -10313,8 +9614,10 @@ Default config: ```lua { "systemd" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/systemd_ls.lua:2](../lua/lspconfig/configs/systemd_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -10331,7 +9634,7 @@ npm install --global tabby-agent ``` Snippet to enable the language server: >lua - require'lspconfig'.tabby_ml.setup{} + vim.lsp.enable('tabby_ml') Default config: @@ -10343,58 +9646,9 @@ Default config: ```lua {} ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/tabby_ml.lua:2](../lua/lspconfig/configs/tabby_ml.lua#L2) -- `single_file_support` : `true` - - ------------------------------------------------------------------------------- -tailwindcss - -https://github.com/tailwindlabs/tailwindcss-intellisense - -Tailwind CSS Language Server can be installed via npm: -```sh -npm install -g @tailwindcss/language-server -``` - -Snippet to enable the language server: >lua - require'lspconfig'.tailwindcss.setup{} - - -Default config: -- `cmd` : +- `root_markers` : ```lua - { "tailwindcss-language-server", "--stdio" } - ``` -- `filetypes` : - ```lua - { "aspnetcorerazor", "astro", "astro-markdown", "blade", "clojure", "django-html", "htmldjango", "edge", "eelixir", "elixir", "ejs", "erb", "eruby", "gohtml", "gohtmltmpl", "haml", "handlebars", "hbs", "html", "htmlangular", "html-eex", "heex", "jade", "leaf", "liquid", "markdown", "mdx", "mustache", "njk", "nunjucks", "php", "razor", "slim", "twig", "css", "less", "postcss", "sass", "scss", "stylus", "sugarss", "javascript", "javascriptreact", "reason", "rescript", "typescript", "typescriptreact", "vue", "svelte", "templ" } - ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/tailwindcss.lua:4](../lua/lspconfig/configs/tailwindcss.lua#L4) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/tailwindcss.lua:4](../lua/lspconfig/configs/tailwindcss.lua#L4) -- `settings` : - ```lua - { - tailwindCSS = { - classAttributes = { "class", "className", "class:list", "classList", "ngClass" }, - includeLanguages = { - eelixir = "html-eex", - eruby = "erb", - htmlangular = "html", - templ = "html" - }, - lint = { - cssConflict = "warning", - invalidApply = "error", - invalidConfigPath = "error", - invalidScreen = "error", - invalidTailwindDirective = "error", - invalidVariant = "error", - recommendedVariantOrder = "warning" - }, - validate = true - } - } + { ".git" } ``` @@ -10411,7 +9665,7 @@ cargo install --features lsp --locked taplo-cli ``` Snippet to enable the language server: >lua - require'lspconfig'.taplo.setup{} + vim.lsp.enable('taplo') Default config: @@ -10423,8 +9677,10 @@ Default config: ```lua { "toml" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/taplo.lua:2](../lua/lspconfig/configs/taplo.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -10437,7 +9693,7 @@ The Language Server for the LLVM TableGen language `tblgen-lsp-server` can be installed at the llvm-project repository (https://github.com/llvm/llvm-project) Snippet to enable the language server: >lua - require'lspconfig'.tblgen_lsp_server.setup{} + vim.lsp.enable('tblgen_lsp_server') Default config: @@ -10449,7 +9705,10 @@ Default config: ```lua { "tablegen" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/tblgen_lsp_server.lua:15](../lua/lspconfig/configs/tblgen_lsp_server.lua#L15) +- `root_markers` : + ```lua + { "tablegen_compile_commands.yml", ".git" } + ``` ------------------------------------------------------------------------------ @@ -10468,7 +9727,7 @@ Optional Command Args: * "--verbose=true" - Increases log level. Does nothing unless log-mode is set Snippet to enable the language server: >lua - require'lspconfig'.teal_ls.setup{} + vim.lsp.enable('teal_ls') Default config: @@ -10480,7 +9739,10 @@ Default config: ```lua { "teal" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/teal_ls.lua:4](../lua/lspconfig/configs/teal_ls.lua#L4) +- `root_markers` : + ```lua + { "tlconfig.lua" } + ``` ------------------------------------------------------------------------------ @@ -10491,7 +9753,7 @@ https://templ.guide The official language server for the templ HTML templating language. Snippet to enable the language server: >lua - require'lspconfig'.templ.setup{} + vim.lsp.enable('templ') Default config: @@ -10503,7 +9765,10 @@ Default config: ```lua { "templ" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/templ.lua:4](../lua/lspconfig/configs/templ.lua#L4) +- `root_markers` : + ```lua + { "go.work", "go.mod", ".git" } + ``` ------------------------------------------------------------------------------ @@ -10538,7 +9803,7 @@ choice: - less stability (due to reliance on Terraform's own internal packages) Snippet to enable the language server: >lua - require'lspconfig'.terraform_lsp.setup{} + vim.lsp.enable('terraform_lsp') Default config: @@ -10550,7 +9815,10 @@ Default config: ```lua { "terraform", "hcl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/terraform_lsp.lua:4](../lua/lspconfig/configs/terraform_lsp.lua#L4) +- `root_markers` : + ```lua + { ".terraform", ".git" } + ``` ------------------------------------------------------------------------------ @@ -10589,7 +9857,7 @@ Instead you should use `init_options` which passes the settings as part of the L [as is required by terraform-ls](https://github.com/hashicorp/terraform-ls/blob/main/docs/SETTINGS.md#how-to-pass-settings). Snippet to enable the language server: >lua - require'lspconfig'.terraformls.setup{} + vim.lsp.enable('terraformls') Default config: @@ -10601,7 +9869,10 @@ Default config: ```lua { "terraform", "terraform-vars" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/terraformls.lua:4](../lua/lspconfig/configs/terraformls.lua#L4) +- `root_markers` : + ```lua + { ".terraform", ".git" } + ``` ------------------------------------------------------------------------------ @@ -10614,18 +9885,8 @@ A completion engine built from scratch for (La)TeX. See https://github.com/latex-lsp/texlab/wiki/Configuration for configuration options. Snippet to enable the language server: >lua - require'lspconfig'.texlab.setup{} - + vim.lsp.enable('texlab') -Commands: -- TexlabBuild: Build the current buffer -- TexlabCancelBuild: Cancel the current build -- TexlabChangeEnvironment: Change the environment at current position -- TexlabCleanArtifacts: Clean the artifacts -- TexlabCleanAuxiliary: Clean the auxiliary files -- TexlabDependencyGraph: Show the dependency graph -- TexlabFindEnvironments: Find the environments at current position -- TexlabForward: Forward search from current position Default config: - `cmd` : @@ -10636,7 +9897,11 @@ Default config: ```lua { "tex", "plaintex", "bib" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/texlab.lua:159](../lua/lspconfig/configs/texlab.lua#L159) +- `on_attach` source (use "gF" to open): [../lsp/texlab.lua:163](../lsp/texlab.lua#L163) +- `root_markers` : + ```lua + { ".git", ".latexmkrc", ".texlabroot", "texlabroot", "Tectonic.toml" } + ``` - `settings` : ```lua { @@ -10664,7 +9929,6 @@ Default config: } } ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -10682,7 +9946,7 @@ For quick testing, LanguageTool is enabled in the default `nvim-lspconfig` confi To install run: `pip install textLSP` Snippet to enable the language server: >lua - require'lspconfig'.textlsp.setup{} + vim.lsp.enable('textlsp') Default config: @@ -10694,7 +9958,10 @@ Default config: ```lua { "text", "tex", "org" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/textlsp.lua:2](../lua/lspconfig/configs/textlsp.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua { @@ -10717,7 +9984,6 @@ Default config: } } ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -10729,7 +9995,7 @@ A pluggable Terraform linter that can act as lsp server. Installation instructions can be found in https://github.com/terraform-linters/tflint#installation. Snippet to enable the language server: >lua - require'lspconfig'.tflint.setup{} + vim.lsp.enable('tflint') Default config: @@ -10741,7 +10007,10 @@ Default config: ```lua { "terraform" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/tflint.lua:4](../lua/lspconfig/configs/tflint.lua#L4) +- `root_markers` : + ```lua + { ".terraform", ".git", ".tflint.hcl" } + ``` ------------------------------------------------------------------------------ @@ -10757,13 +10026,13 @@ https://github.com/Shopify/theme-check#installation If installed via Homebrew, `cmd` must be set to 'theme-check-liquid-server' ```lua -require lspconfig.theme_check.setup { +vim.lsp.config('theme_check, { cmd = { 'theme-check-liquid-server' } -} +}) ``` Snippet to enable the language server: >lua - require'lspconfig'.theme_check.setup{} + vim.lsp.enable('theme_check') Default config: @@ -10775,7 +10044,10 @@ Default config: ```lua { "liquid" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/theme_check.lua:6](../lua/lspconfig/configs/theme_check.lua#L6) +- `root_markers` : + ```lua + { ".theme-check.yml" } + ``` - `settings` : ```lua {} @@ -10790,7 +10062,7 @@ https://github.com/joyme123/thrift-ls you can install thriftls by mason or download binary here: https://github.com/joyme123/thrift-ls/releases Snippet to enable the language server: >lua - require'lspconfig'.thriftls.setup{} + vim.lsp.enable('thriftls') Default config: @@ -10802,8 +10074,10 @@ Default config: ```lua { "thrift" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/thriftls.lua:4](../lua/lspconfig/configs/thriftls.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".thrift" } + ``` ------------------------------------------------------------------------------ @@ -10820,7 +10094,7 @@ autocmd BufRead Tiltfile setf=tiltfile ``` Snippet to enable the language server: >lua - require'lspconfig'.tilt_ls.setup{} + vim.lsp.enable('tilt_ls') Default config: @@ -10832,8 +10106,10 @@ Default config: ```lua { "tiltfile" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/tilt_ls.lua:2](../lua/lspconfig/configs/tilt_ls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -10850,7 +10126,7 @@ Currently some of Tinymist's workspace commands are supported, namely: `LspTinymistGetDocumentMetrics`. Snippet to enable the language server: >lua - require'lspconfig'.tinymist.setup{} + vim.lsp.enable('tinymist') Default config: @@ -10862,9 +10138,11 @@ Default config: ```lua { "typst" } ``` -- `on_attach` source (use "gF" to visit): [../lua/lspconfig/configs/tinymist.lua:46](../lua/lspconfig/configs/tinymist.lua#L46) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/tinymist.lua:46](../lua/lspconfig/configs/tinymist.lua#L46) -- `single_file_support` : `true` +- `on_attach` source (use "gF" to open): [../lsp/tinymist.lua:56](../lsp/tinymist.lua#L56) +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -10907,7 +10185,7 @@ adds Vue support to this language server. *IMPORTANT*: It is crucial to ensure that `@vue/typescript-plugin` and `volar `are of identical versions. ```lua -require'lspconfig'.ts_ls.setup{ +vim.lsp.config('ts_ls', { init_options = { plugins = { { @@ -10922,7 +10200,7 @@ require'lspconfig'.ts_ls.setup{ "typescript", "vue", }, -} +}) -- You must make sure volar is setup -- e.g. require'lspconfig'.volar.setup{} @@ -10937,7 +10215,7 @@ require'lspconfig'.ts_ls.setup{ `filetypes` is extended here to include Vue SFC. Snippet to enable the language server: >lua - require'lspconfig'.ts_ls.setup{} + vim.lsp.enable('ts_ls') Default config: @@ -10955,17 +10233,19 @@ Default config: hostInfo = "neovim" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ts_ls.lua:4](../lua/lspconfig/configs/ts_ls.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "tsconfig.json", "jsconfig.json", "package.json", ".git" } + ``` ------------------------------------------------------------------------------ ts_query_ls https://github.com/ribru17/ts_query_ls -Can be configured by passing a "settings" object to `ts_query_ls.setup{}`: +Can be configured by passing a "settings" object to `vim.lsp.config('ts_query_ls', {})`: ```lua -require('lspconfig').ts_query_ls.setup{ +vim.lsp.config('ts_query_ls', { settings = { parser_install_directories = { -- If using nvim-treesitter with lazy.nvim @@ -10985,11 +10265,11 @@ require('lspconfig').ts_query_ls.setup{ 'languages/src/([^/]+)/[^/]+\\.scm$', }, }, -} +}) ``` Snippet to enable the language server: >lua - require'lspconfig'.ts_query_ls.setup{} + vim.lsp.enable('ts_query_ls') Default config: @@ -11001,7 +10281,10 @@ Default config: ```lua { "query" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ts_query_ls.lua:4](../lua/lspconfig/configs/ts_query_ls.lua#L4) +- `root_markers` : + ```lua + { "queries", ".git" } + ``` - `settings` : ```lua { @@ -11027,7 +10310,7 @@ npm install -g @typespec/compiler ``` Snippet to enable the language server: >lua - require'lspconfig'.tsp_server.setup{} + vim.lsp.enable('tsp_server') Default config: @@ -11039,7 +10322,10 @@ Default config: ```lua { "typespec" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/tsp_server.lua:4](../lua/lspconfig/configs/tsp_server.lua#L4) +- `root_markers` : + ```lua + { "tspconfig.yaml", ".git" } + ``` ------------------------------------------------------------------------------ @@ -11048,7 +10334,7 @@ ttags https://github.com/npezza93/ttags Snippet to enable the language server: >lua - require'lspconfig'.ttags.setup{} + vim.lsp.enable('ttags') Default config: @@ -11060,7 +10346,10 @@ Default config: ```lua { "ruby", "rust", "javascript", "haskell" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ttags.lua:4](../lua/lspconfig/configs/ttags.lua#L4) +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -11081,7 +10370,7 @@ yarn global add turbo-language-server ``` Snippet to enable the language server: >lua - require'lspconfig'.turbo_ls.setup{} + vim.lsp.enable('turbo_ls') Default config: @@ -11093,7 +10382,10 @@ Default config: ```lua { "html", "ruby", "eruby", "blade", "php" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/turbo_ls.lua:2](../lua/lspconfig/configs/turbo_ls.lua#L2) +- `root_markers` : + ```lua + { "Gemfile", ".git" } + ``` ------------------------------------------------------------------------------ @@ -11105,7 +10397,7 @@ installable via npm install -g turtle-language-server or yarn global add turtle- requires node. Snippet to enable the language server: >lua - require'lspconfig'.turtle_ls.setup{} + vim.lsp.enable('turtle_ls') Default config: @@ -11119,7 +10411,10 @@ Default config: ```lua { "turtle", "ttl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/turtle_ls.lua:28](../lua/lspconfig/configs/turtle_ls.lua#L28) +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -11133,7 +10428,7 @@ FFI navigator can be installed with `pip install ffi-navigator`, buf for more de https://github.com/tqchen/ffi-navigator?tab=readme-ov-file#installation Snippet to enable the language server: >lua - require'lspconfig'.tvm_ffi_navigator.setup{} + vim.lsp.enable('tvm_ffi_navigator') Default config: @@ -11145,7 +10440,10 @@ Default config: ```lua { "python", "cpp" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/tvm_ffi_navigator.lua:4](../lua/lspconfig/configs/tvm_ffi_navigator.lua#L4) +- `root_markers` : + ```lua + { "pyproject.toml", ".git" } + ``` ------------------------------------------------------------------------------ @@ -11159,7 +10457,7 @@ npm install -g twiggy-language-server ``` Snippet to enable the language server: >lua - require'lspconfig'.twiggy_language_server.setup{} + vim.lsp.enable('twiggy_language_server') Default config: @@ -11171,8 +10469,10 @@ Default config: ```lua { "twig" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/twiggy_language_server.lua:4](../lua/lspconfig/configs/twiggy_language_server.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "composer.json", ".git" } + ``` ------------------------------------------------------------------------------ @@ -11183,7 +10483,7 @@ https://github.com/ruby/typeprof `typeprof` is the built-in analysis and LSP tool for Ruby 3.1+. Snippet to enable the language server: >lua - require'lspconfig'.typeprof.setup{} + vim.lsp.enable('typeprof') Default config: @@ -11195,7 +10495,10 @@ Default config: ```lua { "ruby", "eruby" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/typeprof.lua:4](../lua/lspconfig/configs/typeprof.lua#L4) +- `root_markers` : + ```lua + { "Gemfile", ".git" } + ``` ------------------------------------------------------------------------------ @@ -11209,7 +10512,7 @@ source code spell checker, written in Rust. Download it from the releases page on GitHub: https://github.com/tekumara/typos-lsp/releases Snippet to enable the language server: >lua - require'lspconfig'.typos_lsp.setup{} + vim.lsp.enable('typos_lsp') Default config: @@ -11217,12 +10520,14 @@ Default config: ```lua { "typos-lsp" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/typos_lsp.lua:4](../lua/lspconfig/configs/typos_lsp.lua#L4) +- `root_markers` : + ```lua + { "typos.toml", "_typos.toml", ".typos.toml" } + ``` - `settings` : ```lua {} ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -11233,7 +10538,7 @@ https://github.com/nvarner/typst-lsp Language server for Typst. Snippet to enable the language server: >lua - require'lspconfig'.typst_lsp.setup{} + vim.lsp.enable('typst_lsp') Default config: @@ -11245,8 +10550,10 @@ Default config: ```lua { "typst" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/typst_lsp.lua:2](../lua/lspconfig/configs/typst_lsp.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -11259,7 +10566,7 @@ The builtin language server of the Uiua interpreter. The Uiua interpreter can be installed with `cargo install uiua` Snippet to enable the language server: >lua - require'lspconfig'.uiua.setup{} + vim.lsp.enable('uiua') Default config: @@ -11271,7 +10578,10 @@ Default config: ```lua { "uiua" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/uiua.lua:4](../lua/lspconfig/configs/uiua.lua#L4) +- `root_markers` : + ```lua + { "main.ua", ".fmt.ua", ".git" } + ``` ------------------------------------------------------------------------------ @@ -11286,7 +10596,7 @@ npm i ungrammar-languageserver -g ``` Snippet to enable the language server: >lua - require'lspconfig'.ungrammar_languageserver.setup{} + vim.lsp.enable('ungrammar_languageserver') Default config: @@ -11298,7 +10608,10 @@ Default config: ```lua { "ungrammar" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ungrammar_languageserver.lua:2](../lua/lspconfig/configs/ungrammar_languageserver.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua { @@ -11312,7 +10625,6 @@ Default config: } } ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -11321,7 +10633,7 @@ unison https://github.com/unisonweb/unison/blob/trunk/docs/language-server.markdown Snippet to enable the language server: >lua - require'lspconfig'.unison.setup{} + vim.lsp.enable('unison') Default config: @@ -11333,7 +10645,7 @@ Default config: ```lua { "unison" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/unison.lua:4](../lua/lspconfig/configs/unison.lua#L4) +- `root_dir` source (use "gF" to open): [../lsp/unison.lua:6](../lsp/unison.lua#L6) - `settings` : ```lua {} @@ -11351,7 +10663,7 @@ npm i unocss-language-server -g ``` Snippet to enable the language server: >lua - require'lspconfig'.unocss.setup{} + vim.lsp.enable('unocss') Default config: @@ -11363,7 +10675,10 @@ Default config: ```lua { "erb", "haml", "hbs", "html", "css", "postcss", "javascript", "javascriptreact", "markdown", "ejs", "php", "svelte", "typescript", "typescriptreact", "vue-html", "vue", "sass", "scss", "less", "stylus", "astro", "rescript", "rust" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/unocss.lua:4](../lua/lspconfig/configs/unocss.lua#L4) +- `root_markers` : + ```lua + { "unocss.config.js", "unocss.config.ts", "uno.config.js", "uno.config.ts" } + ``` ------------------------------------------------------------------------------ @@ -11384,7 +10699,7 @@ vim.cmd([[au BufRead,BufNewFile *.uvl setfiletype uvl]]) ``` Snippet to enable the language server: >lua - require'lspconfig'.uvls.setup{} + vim.lsp.enable('uvls') Default config: @@ -11396,8 +10711,10 @@ Default config: ```lua { "uvl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/uvls.lua:2](../lua/lspconfig/configs/uvls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -11410,7 +10727,7 @@ V language server. `v-analyzer` can be installed by following the instructions [here](https://github.com/vlang/v-analyzer#installation). Snippet to enable the language server: >lua - require'lspconfig'.v_analyzer.setup{} + vim.lsp.enable('v_analyzer') Default config: @@ -11422,7 +10739,10 @@ Default config: ```lua { "v", "vsh", "vv" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/v_analyzer.lua:4](../lua/lspconfig/configs/v_analyzer.lua#L4) +- `root_markers` : + ```lua + { "v.mod", ".git" } + ``` ------------------------------------------------------------------------------ @@ -11430,21 +10750,21 @@ vacuum Vacuum is the worlds fastest OpenAPI 3, OpenAPI 2 / Swagger linter and quality analysis tool. -You can install vacuum using mason or follow the instructions here: https://github.com/daveshanley/vacuum + You can install vacuum using mason or follow the instructions here: https://github.com/daveshanley/vacuum -The file types are not detected automatically, you can register them manually (see below) or override the filetypes: + The file types are not detected automatically, you can register them manually (see below) or override the filetypes: -```lua -vim.filetype.add { - pattern = { - ['openapi.*%.ya?ml'] = 'yaml.openapi', - ['openapi.*%.json'] = 'json.openapi', - }, -} -``` + ```lua + vim.filetype.add { + pattern = { + ['openapi.*%.ya?ml'] = 'yaml.openapi', + ['openapi.*%.json'] = 'json.openapi', + }, + } + ``` Snippet to enable the language server: >lua - require'lspconfig'.vacuum.setup{} + vim.lsp.enable('vacuum') Default config: @@ -11456,8 +10776,10 @@ Default config: ```lua { "yaml.openapi", "json.openapi" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/vacuum.lua:2](../lua/lspconfig/configs/vacuum.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -11466,7 +10788,7 @@ vala_ls https://github.com/Prince781/vala-language-server Snippet to enable the language server: >lua - require'lspconfig'.vala_ls.setup{} + vim.lsp.enable('vala_ls') Default config: @@ -11478,8 +10800,7 @@ Default config: ```lua { "vala", "genie" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/vala_ls.lua:25](../lua/lspconfig/configs/vala_ls.lua#L25) -- `single_file_support` : `true` +- `root_dir` source (use "gF" to open): [../lsp/vala_ls.lua:27](../lsp/vala_ls.lua#L27) ------------------------------------------------------------------------------ @@ -11490,7 +10811,7 @@ https://github.com/errata-ai/vale-ls An implementation of the Language Server Protocol (LSP) for the Vale command-line tool. Snippet to enable the language server: >lua - require'lspconfig'.vale_ls.setup{} + vim.lsp.enable('vale_ls') Default config: @@ -11502,83 +10823,10 @@ Default config: ```lua { "markdown", "text", "tex", "rst" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/vale_ls.lua:4](../lua/lspconfig/configs/vale_ls.lua#L4) -- `single_file_support` : `true` - - ------------------------------------------------------------------------------- -vdmj - -https://github.com/nickbattle/vdmj - -The VDMJ language server can be installed by cloning the VDMJ repository and -running `mvn clean install`. - -Various options are provided to configure the language server (see below). In -particular: -- `annotation_paths` is a list of folders and/or jar file paths for annotations -that should be used with the language server; -- any value of `debugger_port` less than zero will disable the debugger; note -that if a non-zero value is used, only one instance of the server can be active -at a time. - -More settings for VDMJ can be changed in a file called `vdmj.properties` under -`root_dir/.vscode`. For a description of the available settings, see -[Section 7 of the VDMJ User Guide](https://raw.githubusercontent.com/nickbattle/vdmj/master/vdmj/documentation/UserGuide.pdf). - -Note: proof obligations and combinatorial testing are not currently supported -by neovim. - -Snippet to enable the language server: >lua - require'lspconfig'.vdmj.setup{} - - -Default config: -- `cmd` : - ```lua - { "java" } - ``` -- `filetypes` : +- `root_markers` : ```lua - { "vdmsl", "vdmpp", "vdmrt" } + { ".vale.ini" } ``` -- `options` : - ```lua - { - annotation_paths = {}, - debugger_port = -1, - high_precision = false, - java = "/usr/lib/jvm/temurin-17-jdk-amd64/bin/java", - java_opts = { "-Xmx3000m", "-Xss1m" }, - logfile = "/home/user/.cache/nvim/vdm-lsp.log", - mavenrepo = "/home/user/.m2/repository/com/fujitsu" - } - ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/vdmj.lua:44](../lua/lspconfig/configs/vdmj.lua#L44) - - ------------------------------------------------------------------------------- -vectorcode_server - -https://github.com/Davidyz/VectorCode - -A Language Server Protocol implementation for VectorCode, a code repository indexing tool. - -Snippet to enable the language server: >lua - require'lspconfig'.vectorcode_server.setup{} - - -Default config: -- `cmd` : - ```lua - { "vectorcode-server" } - ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/vectorcode_server.lua:2](../lua/lspconfig/configs/vectorcode_server.lua#L2) -- `settings` : - ```lua - {} - ``` -- `single_file_support` : `false` ------------------------------------------------------------------------------ @@ -11594,7 +10842,7 @@ and placed in a directory on PATH. See https://github.com/chipsalliance/verible/tree/master/verilog/tools/ls/README.md for options. Snippet to enable the language server: >lua - require'lspconfig'.verible.setup{} + vim.lsp.enable('verible') Default config: @@ -11606,7 +10854,10 @@ Default config: ```lua { "systemverilog", "verilog" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/verible.lua:2](../lua/lspconfig/configs/verible.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -11629,7 +10880,7 @@ cargo install --git https://github.com/vivekmalneedi/veridian.git ``` Snippet to enable the language server: >lua - require'lspconfig'.veridian.setup{} + vim.lsp.enable('veridian') Default config: @@ -11641,7 +10892,10 @@ Default config: ```lua { "systemverilog", "verilog" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/veridian.lua:2](../lua/lspconfig/configs/veridian.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -11657,7 +10911,7 @@ Language server for Veryl ``` Snippet to enable the language server: >lua - require'lspconfig'.veryl_ls.setup{} + vim.lsp.enable('veryl_ls') Default config: @@ -11669,7 +10923,10 @@ Default config: ```lua { "veryl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/veryl_ls.lua:2](../lua/lspconfig/configs/veryl_ls.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -11703,7 +10960,7 @@ lib1.files = [ ``` Snippet to enable the language server: >lua - require'lspconfig'.vhdl_ls.setup{} + vim.lsp.enable('vhdl_ls') Default config: @@ -11715,8 +10972,10 @@ Default config: ```lua { "vhd", "vhdl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/vhdl_ls.lua:9](../lua/lspconfig/configs/vhdl_ls.lua#L9) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "vhdl_ls.toml", ".vhdl_ls.toml" } + ``` ------------------------------------------------------------------------------ @@ -11730,7 +10989,7 @@ npm install -g vim-language-server ``` Snippet to enable the language server: >lua - require'lspconfig'.vimls.setup{} + vim.lsp.enable('vimls') Default config: @@ -11764,8 +11023,10 @@ Default config: vimruntime = "" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/vimls.lua:2](../lua/lspconfig/configs/vimls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -11780,17 +11041,17 @@ For manual installation, download the .vsix archive file from the GitHub releases. Then, configure `cmd` to run the Node script at the unpacked location: ```lua -require'lspconfig'.visualforce_ls.setup { +vim.lsp.config('visualforce_ls', { cmd = { 'node', '/path/to/unpacked/archive/extension/node_modules/@salesforce/salesforcedx-visualforce-language-server/out/src/visualforceServer.js', '--stdio' } -} +}) ``` Snippet to enable the language server: >lua - require'lspconfig'.visualforce_ls.setup{} + vim.lsp.enable('visualforce_ls') Default config: @@ -11807,7 +11068,10 @@ Default config: } } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/visualforce_ls.lua:4](../lua/lspconfig/configs/visualforce_ls.lua#L4) +- `root_markers` : + ```lua + { "sfdx-project.json" } + ``` ------------------------------------------------------------------------------ @@ -11820,7 +11084,7 @@ V language server. `v-language-server` can be installed by following the instructions [here](https://github.com/vlang/vls#installation). Snippet to enable the language server: >lua - require'lspconfig'.vls.setup{} + vim.lsp.enable('vls') Default config: @@ -11832,108 +11096,10 @@ Default config: ```lua { "v", "vlang" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/vls.lua:4](../lua/lspconfig/configs/vls.lua#L4) - - ------------------------------------------------------------------------------- -volar - -https://github.com/vuejs/language-tools/tree/master/packages/language-server - -Volar language server for Vue - -Volar can be installed via npm: -```sh -npm install -g @vue/language-server -``` - -Volar by default supports Vue 3 projects. -For Vue 2 projects, [additional configuration](https://github.com/vuejs/language-tools/blob/master/extensions/vscode/README.md?plain=1#L19) are required. - -**Hybrid Mode (by default)** - -In this mode, the Vue Language Server exclusively manages the CSS/HTML sections. -You need the `ts_ls` server with the `@vue/typescript-plugin` plugin to support TypeScript in `.vue` files. -See `ts_ls` section for more information - -**No Hybrid Mode** - -Volar will run embedded `ts_ls` therefore there is no need to run it separately. -```lua -local lspconfig = require('lspconfig') - -lspconfig.volar.setup { - -- add filetypes for typescript, javascript and vue - filetypes = { 'typescript', 'javascript', 'javascriptreact', 'typescriptreact', 'vue' }, - init_options = { - vue = { - -- disable hybrid mode - hybridMode = false, - }, - }, -} --- you must remove ts_ls setup --- lspconfig.ts_ls.setup {} -``` - -**Overriding the default TypeScript Server used by Volar** - -The default config looks for TypeScript in the local `node_modules`. This can lead to issues -e.g. when working on a [monorepo](https://monorepo.tools/). The alternatives are: - -- use a global TypeScript Server installation -```lua -require'lspconfig'.volar.setup { - init_options = { - typescript = { - -- replace with your global TypeScript library path - tsdk = '/path/to/node_modules/typescript/lib' - } - } -} -``` - -- use a local server and fall back to a global TypeScript Server installation -```lua -require'lspconfig'.volar.setup { - init_options = { - typescript = { - -- replace with your global TypeScript library path - tsdk = '/path/to/node_modules/typescript/lib' - } - }, - on_new_config = function(new_config, new_root_dir) - local lib_path = vim.fs.find('node_modules/typescript/lib', { path = new_root_dir, upward = true })[1] - if lib_path then - new_config.init_options.typescript.tsdk = lib_path - end - end -} -``` - -Snippet to enable the language server: >lua - require'lspconfig'.volar.setup{} - - -Default config: -- `cmd` : - ```lua - { "vue-language-server", "--stdio" } - ``` -- `filetypes` : +- `root_markers` : ```lua - { "vue" } + { "v.mod", ".git" } ``` -- `init_options` : - ```lua - { - typescript = { - tsdk = "" - } - } - ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/volar.lua:16](../lua/lspconfig/configs/volar.lua#L16) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/volar.lua:16](../lua/lspconfig/configs/volar.lua#L16) ------------------------------------------------------------------------------ @@ -11942,7 +11108,7 @@ vscoqtop https://github.com/coq-community/vscoq Snippet to enable the language server: >lua - require'lspconfig'.vscoqtop.setup{} + vim.lsp.enable('vscoqtop') Default config: @@ -11954,8 +11120,10 @@ Default config: ```lua { "coq" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/vscoqtop.lua:4](../lua/lspconfig/configs/vscoqtop.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "_CoqProject", ".git" } + ``` ------------------------------------------------------------------------------ @@ -11974,7 +11142,7 @@ or [`jsconfig.json`](https://code.visualstudio.com/docs/languages/jsconfig) to the root of your project. Snippet to enable the language server: >lua - require'lspconfig'.vtsls.setup{} + vim.lsp.enable('vtsls') Default config: @@ -11986,8 +11154,10 @@ Default config: ```lua { "javascript", "javascriptreact", "javascript.jsx", "typescript", "typescriptreact", "typescript.tsx" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/vtsls.lua:4](../lua/lspconfig/configs/vtsls.lua#L4) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { "tsconfig.json", "package.json", "jsconfig.json", ".git" } + ``` ------------------------------------------------------------------------------ @@ -12002,7 +11172,7 @@ npm install -g vls ``` Snippet to enable the language server: >lua - require'lspconfig'.vuels.setup{} + vim.lsp.enable('vuels') Default config: @@ -12055,7 +11225,10 @@ Default config: } } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/vuels.lua:4](../lua/lspconfig/configs/vuels.lua#L4) +- `root_markers` : + ```lua + { "package.json", "vue.config.js" } + ``` ------------------------------------------------------------------------------ @@ -12067,7 +11240,7 @@ WebAssembly Language Tools aims to provide and improve the editing experience of It also provides an out-of-the-box formatter (a.k.a. pretty printer) for WebAssembly Text Format. Snippet to enable the language server: >lua - require'lspconfig'.wasm_language_tools.setup{} + vim.lsp.enable('wasm_language_tools') Default config: @@ -12079,7 +11252,6 @@ Default config: ```lua { "wat" } ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -12093,7 +11265,7 @@ cargo install --git https://github.com/wgsl-analyzer/wgsl-analyzer wgsl-analyzer ``` Snippet to enable the language server: >lua - require'lspconfig'.wgsl_analyzer.setup{} + vim.lsp.enable('wgsl_analyzer') Default config: @@ -12105,7 +11277,10 @@ Default config: ```lua { "wgsl" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/wgsl_analyzer.lua:4](../lua/lspconfig/configs/wgsl_analyzer.lua#L4) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua {} @@ -12134,11 +11309,11 @@ where the relative filepath is the path relative to the open yaml file, and the is the filepath relative to the filesystem root ('/' on unix systems) 2. Associated a schema url, relative , or absolute (to root of project, not to filesystem root) path to -the a glob pattern relative to the detected project root. Check `:LspInfo` to determine the resolved project +the a glob pattern relative to the detected project root. Check `:checkhealth vim.lsp` to determine the resolved project root. ```lua -require('lspconfig').yamlls.setup { +vim.lsp.config('yamlls', { ... -- other configuration for setup {} settings = { yaml = { @@ -12150,7 +11325,7 @@ require('lspconfig').yamlls.setup { }, }, } -} +}) ``` Currently, kubernetes is special-cased in yammls, see the following upstream issues: @@ -12160,7 +11335,7 @@ Currently, kubernetes is special-cased in yammls, see the following upstream iss To override a schema to use a specific k8s schema version (for example, to use 1.18): ```lua -require('lspconfig').yamlls.setup { +vim.lsp.config('yamlls', { ... -- other configuration for setup {} settings = { yaml = { @@ -12171,11 +11346,11 @@ require('lspconfig').yamlls.setup { }, }, } -} +}) ``` Snippet to enable the language server: >lua - require'lspconfig'.yamlls.setup{} + vim.lsp.enable('yamlls') Default config: @@ -12187,7 +11362,10 @@ Default config: ```lua { "yaml", "yaml.docker-compose", "yaml.gitlab" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/yamlls.lua:2](../lua/lspconfig/configs/yamlls.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` - `settings` : ```lua { @@ -12198,7 +11376,6 @@ Default config: } } ``` -- `single_file_support` : `true` ------------------------------------------------------------------------------ @@ -12209,7 +11386,7 @@ https://github.com/TypeFox/yang-lsp A Language Server for the YANG data modeling language. Snippet to enable the language server: >lua - require'lspconfig'.yang_lsp.setup{} + vim.lsp.enable('yang_lsp') Default config: @@ -12221,7 +11398,10 @@ Default config: ```lua { "yang" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/yang_lsp.lua:2](../lua/lspconfig/configs/yang_lsp.lua#L2) +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -12236,7 +11416,7 @@ This plugin runs yara.compile on every save, parses the errors, and returns list Language Server: https://github.com/avast/yls Snippet to enable the language server: >lua - require'lspconfig'.yls.setup{} + vim.lsp.enable('yls') Default config: @@ -12248,8 +11428,10 @@ Default config: ```lua { "yar", "yara" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/yls.lua:2](../lua/lspconfig/configs/yls.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -12260,7 +11442,7 @@ https://ziggy-lang.io/documentation/ziggy-lsp/ Language server for the Ziggy data serialization format Snippet to enable the language server: >lua - require'lspconfig'.ziggy.setup{} + vim.lsp.enable('ziggy') Default config: @@ -12272,8 +11454,10 @@ Default config: ```lua { "ziggy" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ziggy.lua:2](../lua/lspconfig/configs/ziggy.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -12284,7 +11468,7 @@ https://ziggy-lang.io/documentation/ziggy-lsp/ Language server for schema files of the Ziggy data serialization format Snippet to enable the language server: >lua - require'lspconfig'.ziggy_schema.setup{} + vim.lsp.enable('ziggy_schema') Default config: @@ -12296,8 +11480,10 @@ Default config: ```lua { "ziggy_schema" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/ziggy_schema.lua:2](../lua/lspconfig/configs/ziggy_schema.lua#L2) -- `single_file_support` : `true` +- `root_markers` : + ```lua + { ".git" } + ``` ------------------------------------------------------------------------------ @@ -12308,13 +11494,8 @@ https://github.com/mickael-menu/zk A plain text note-taking assistant Snippet to enable the language server: >lua - require'lspconfig'.zk.setup{} - + vim.lsp.enable('zk') -Commands: -- ZkIndex: ZkIndex -- ZkList: ZkList -- ZkNew: ZkNew Default config: - `cmd` : @@ -12325,32 +11506,11 @@ Default config: ```lua { "markdown" } ``` -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/zk.lua:12](../lua/lspconfig/configs/zk.lua#L12) - - ------------------------------------------------------------------------------- -zls - -https://github.com/zigtools/zls - -Zig LSP implementation + Zig Language Server - -Snippet to enable the language server: >lua - require'lspconfig'.zls.setup{} - - -Default config: -- `cmd` : - ```lua - { "zls" } - ``` -- `filetypes` : +- `on_attach` source (use "gF" to open): [../lsp/zk.lua:14](../lsp/zk.lua#L14) +- `root_markers` : ```lua - { "zig", "zir" } + { ".zk" } ``` -- `on_new_config` source (use "gF" to visit): [../lua/lspconfig/configs/zls.lua:4](../lua/lspconfig/configs/zls.lua#L4) -- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/zls.lua:4](../lua/lspconfig/configs/zls.lua#L4) -- `single_file_support` : `true` |
