aboutsummaryrefslogtreecommitdiff
path: root/lsp
diff options
context:
space:
mode:
authorpml68 <contact@pml68.dev>2025-09-16 23:07:41 +0200
committerpml68 <contact@pml68.dev>2025-09-16 23:07:41 +0200
commite90a4f3f66c6e64d187b9f0cbb67133f1a77c0f2 (patch)
treeefa94e86bc58e0f50bd3ec85879c774b0fb3f88d /lsp
parentdocs(README): update image sizes [skip ci] (diff)
downloadnvim-e90a4f3f66c6e64d187b9f0cbb67133f1a77c0f2.tar.gz
feat: move lsp configs to `lsp/`
Diffstat (limited to 'lsp')
-rw-r--r--lsp/asm_lsp.lua3
-rw-r--r--lsp/clangd.lua9
-rw-r--r--lsp/emmet_language_server.lua3
-rw-r--r--lsp/gopls.lua10
-rw-r--r--lsp/jsonls.lua8
-rw-r--r--lsp/lua_ls.lua21
-rw-r--r--lsp/pyright.lua14
-rw-r--r--lsp/rust_analyzer.lua9
8 files changed, 77 insertions, 0 deletions
diff --git a/lsp/asm_lsp.lua b/lsp/asm_lsp.lua
new file mode 100644
index 0000000..da468c7
--- /dev/null
+++ b/lsp/asm_lsp.lua
@@ -0,0 +1,3 @@
+return {
+ single_file_support = true,
+}
diff --git a/lsp/clangd.lua b/lsp/clangd.lua
new file mode 100644
index 0000000..c5d4994
--- /dev/null
+++ b/lsp/clangd.lua
@@ -0,0 +1,9 @@
+return {
+ cmd = {
+ vim.fn.stdpath('data') .. "/mason/bin/clangd",
+ "--header-insertion=never"
+ },
+ on_attach = function(client, bufnr)
+ client.server_capabilities.signatureHelpProvider = false
+ end
+}
diff --git a/lsp/emmet_language_server.lua b/lsp/emmet_language_server.lua
new file mode 100644
index 0000000..18073fd
--- /dev/null
+++ b/lsp/emmet_language_server.lua
@@ -0,0 +1,3 @@
+return {
+ filetypes = { "html", "typescript", "javascript", "css", "sass", "scss", "less", "svelte" },
+}
diff --git a/lsp/gopls.lua b/lsp/gopls.lua
new file mode 100644
index 0000000..a2b5212
--- /dev/null
+++ b/lsp/gopls.lua
@@ -0,0 +1,10 @@
+return {
+ settings = {
+ gopls = {
+ completeUnimported = true,
+ analyses = {
+ unusedparams = true,
+ },
+ },
+ },
+}
diff --git a/lsp/jsonls.lua b/lsp/jsonls.lua
new file mode 100644
index 0000000..c6c0776
--- /dev/null
+++ b/lsp/jsonls.lua
@@ -0,0 +1,8 @@
+return {
+ settings = {
+ json = {
+ schemas = require('schemastore').json.schemas(),
+ validate = { enable = true },
+ },
+ },
+}
diff --git a/lsp/lua_ls.lua b/lsp/lua_ls.lua
new file mode 100644
index 0000000..a212aff
--- /dev/null
+++ b/lsp/lua_ls.lua
@@ -0,0 +1,21 @@
+return {
+ settings = {
+ Lua = {
+ runtime = {
+ version = 'LuaJIT'
+ },
+ diagnostics = {
+ globals = { "vim" },
+ },
+ workspace = {
+ checkThirdParty = false,
+ library = {
+ vim.env.VIMRUNTIME,
+ vim.fn.stdpath "data" .. "/lazy/lazy.nvim/lua/lazy",
+ },
+ maxPreload = 100000,
+ preloadFileSize = 10000,
+ }
+ }
+ }
+}
diff --git a/lsp/pyright.lua b/lsp/pyright.lua
new file mode 100644
index 0000000..b7e9a2a
--- /dev/null
+++ b/lsp/pyright.lua
@@ -0,0 +1,14 @@
+return {
+ single_file_support = true,
+ settings = {
+ python = {
+ analysis = {
+ typeCheckingMode = true,
+ reportUnusedImport = true,
+ autoSearchPaths = true,
+ diagnosticMode = "workspace",
+ useLibraryCodeForTypes = true,
+ },
+ },
+ },
+}
diff --git a/lsp/rust_analyzer.lua b/lsp/rust_analyzer.lua
new file mode 100644
index 0000000..3b687c6
--- /dev/null
+++ b/lsp/rust_analyzer.lua
@@ -0,0 +1,9 @@
+return {
+ settings = {
+ ['rust-analyzer'] = {
+ cargo = {
+ allFeatures = true,
+ },
+ },
+ },
+}