diff options
Diffstat (limited to 'common/config/nvim/lsp')
| -rw-r--r-- | common/config/nvim/lsp/bashls.lua | 4 | ||||
| -rw-r--r-- | common/config/nvim/lsp/clangd.lua | 5 | ||||
| -rw-r--r-- | common/config/nvim/lsp/cssls.lua | 4 | ||||
| -rw-r--r-- | common/config/nvim/lsp/gopls.lua | 41 | ||||
| -rw-r--r-- | common/config/nvim/lsp/html.lua | 4 | ||||
| -rw-r--r-- | common/config/nvim/lsp/jsonls.lua | 4 | ||||
| -rw-r--r-- | common/config/nvim/lsp/lua_ls.lua | 20 | ||||
| -rw-r--r-- | common/config/nvim/lsp/pyright.lua | 12 | ||||
| -rw-r--r-- | common/config/nvim/lsp/rust_analyzer.lua | 5 | ||||
| -rw-r--r-- | common/config/nvim/lsp/ts_ls.lua | 8 | ||||
| -rw-r--r-- | common/config/nvim/lsp/yamlls.lua | 4 |
11 files changed, 111 insertions, 0 deletions
diff --git a/common/config/nvim/lsp/bashls.lua b/common/config/nvim/lsp/bashls.lua new file mode 100644 index 0000000..fc7d709 --- /dev/null +++ b/common/config/nvim/lsp/bashls.lua @@ -0,0 +1,4 @@ +return { + cmd = { "bash-language-server", "start" }, + filetypes = { "sh", "bash" } +}
\ No newline at end of file diff --git a/common/config/nvim/lsp/clangd.lua b/common/config/nvim/lsp/clangd.lua new file mode 100644 index 0000000..4a19600 --- /dev/null +++ b/common/config/nvim/lsp/clangd.lua @@ -0,0 +1,5 @@ +return { + cmd = { "clangd", "--background-index", "--clang-tidy", "--header-insertion=iwyu" }, + filetypes = { "c", "cpp", "objc", "objcpp", "cuda", "proto" }, + root_markers = { ".clangd", ".clang-tidy", ".clang-format", "compile_commands.json", "compile_flags.txt", "configure.ac" } +}
\ No newline at end of file diff --git a/common/config/nvim/lsp/cssls.lua b/common/config/nvim/lsp/cssls.lua new file mode 100644 index 0000000..e734c19 --- /dev/null +++ b/common/config/nvim/lsp/cssls.lua @@ -0,0 +1,4 @@ +return { + cmd = { "vscode-css-language-server", "--stdio" }, + filetypes = { "css", "scss", "less" } +}
\ No newline at end of file diff --git a/common/config/nvim/lsp/gopls.lua b/common/config/nvim/lsp/gopls.lua new file mode 100644 index 0000000..cf959c4 --- /dev/null +++ b/common/config/nvim/lsp/gopls.lua @@ -0,0 +1,41 @@ +return { + cmd = { "gopls" }, + filetypes = { "go", "gomod", "gowork", "gotmpl" }, + root_markers = { "go.work", "go.mod" }, + settings = { + gopls = { + analyses = { + fieldalignment = true, + nilness = true, + unusedparams = true, + unusedwrite = true, + useany = true + }, + codelenses = { + gc_details = false, + generate = true, + regenerate_cgo = true, + run_govulncheck = true, + test = true, + tidy = true, + upgrade_dependency = true, + vendor = true + }, + completeUnimported = true, + directoryFilters = { "-.git", "-.vscode", "-.idea", "-.vscode-test", "-node_modules" }, + gofumpt = true, + hints = { + assignVariableTypes = true, + compositeLiteralFields = true, + compositeLiteralTypes = true, + constantValues = true, + functionTypeParameters = true, + parameterNames = true, + rangeVariableTypes = true + }, + semanticTokens = true, + staticcheck = true, + usePlaceholders = true + } + } +}
\ No newline at end of file diff --git a/common/config/nvim/lsp/html.lua b/common/config/nvim/lsp/html.lua new file mode 100644 index 0000000..5b322b1 --- /dev/null +++ b/common/config/nvim/lsp/html.lua @@ -0,0 +1,4 @@ +return { + cmd = { "vscode-html-language-server", "--stdio" }, + filetypes = { "html" } +}
\ No newline at end of file diff --git a/common/config/nvim/lsp/jsonls.lua b/common/config/nvim/lsp/jsonls.lua new file mode 100644 index 0000000..6474e0a --- /dev/null +++ b/common/config/nvim/lsp/jsonls.lua @@ -0,0 +1,4 @@ +return { + cmd = { "vscode-json-language-server", "--stdio" }, + filetypes = { "json", "jsonc" } +}
\ No newline at end of file diff --git a/common/config/nvim/lsp/lua_ls.lua b/common/config/nvim/lsp/lua_ls.lua new file mode 100644 index 0000000..d248e2e --- /dev/null +++ b/common/config/nvim/lsp/lua_ls.lua @@ -0,0 +1,20 @@ +return { + cmd = { "lua-language-server" }, + filetypes = { "lua" }, + root_markers = { ".luarc.json", ".luarc.jsonc", ".luacheckrc", ".stylua.toml", "stylua.toml", "selene.toml", "selene.yml" }, + settings = { + Lua = { + diagnostics = { + disable = { "undefined-global", "lowercase-global", "unused-local", "unused-vararg", "trailing-space" }, + globals = { "vim", "use", "_G", "packer_plugins", "P" } + }, + telemetry = { + enable = false + }, + workspace = { + checkThirdParty = false, + library = { "/tmp/.mount_nvimOIpamk/usr/share/nvim/runtime", "${3rd}/luv/library", "${3rd}/busted/library" } + } + } + } +}
\ No newline at end of file diff --git a/common/config/nvim/lsp/pyright.lua b/common/config/nvim/lsp/pyright.lua new file mode 100644 index 0000000..f89d41f --- /dev/null +++ b/common/config/nvim/lsp/pyright.lua @@ -0,0 +1,12 @@ +return { + cmd = { "pyright-langserver", "--stdio" }, + filetypes = { "python" }, + root_markers = { "pyproject.toml", "setup.py", "setup.cfg", "requirements.txt", "Pipfile", "pyrightconfig.json" }, + settings = { + python = { + formatting = { + provider = "none" + } + } + } +}
\ No newline at end of file diff --git a/common/config/nvim/lsp/rust_analyzer.lua b/common/config/nvim/lsp/rust_analyzer.lua new file mode 100644 index 0000000..b4522f5 --- /dev/null +++ b/common/config/nvim/lsp/rust_analyzer.lua @@ -0,0 +1,5 @@ +return { + cmd = { "rust-analyzer" }, + filetypes = { "rust" }, + root_markers = { "Cargo.toml", "rust-project.json" } +}
\ No newline at end of file diff --git a/common/config/nvim/lsp/ts_ls.lua b/common/config/nvim/lsp/ts_ls.lua new file mode 100644 index 0000000..940fd3d --- /dev/null +++ b/common/config/nvim/lsp/ts_ls.lua @@ -0,0 +1,8 @@ +return { + cmd = { "typescript-language-server", "--stdio" }, + filetypes = { "javascript", "javascriptreact", "javascript.jsx", "typescript", "typescriptreact", "typescript.tsx" }, + init_options = { + disableAutomaticTypeAcquisition = true + }, + root_markers = { "tsconfig.json", "jsconfig.json", "package.json" } +}
\ No newline at end of file diff --git a/common/config/nvim/lsp/yamlls.lua b/common/config/nvim/lsp/yamlls.lua new file mode 100644 index 0000000..e52d322 --- /dev/null +++ b/common/config/nvim/lsp/yamlls.lua @@ -0,0 +1,4 @@ +return { + cmd = { "yaml-language-server", "--stdio" }, + filetypes = { "yaml", "yml" } +}
\ No newline at end of file |
