diff options
| -rw-r--r-- | flake.nix | 2 | ||||
| -rw-r--r-- | lsp/basedpyright.lua | 23 | ||||
| -rw-r--r-- | lua/config/lsp.lua | 2 |
3 files changed, 27 insertions, 0 deletions
@@ -153,6 +153,8 @@ nixfmt-rfc-style ]; + python = [ basedpyright ]; + qml = [ kdePackages.qtdeclarative ]; rust = [ diff --git a/lsp/basedpyright.lua b/lsp/basedpyright.lua new file mode 100644 index 0000000..79ff625 --- /dev/null +++ b/lsp/basedpyright.lua @@ -0,0 +1,23 @@ +return { + cmd = { "basedpyright-langserver", "--stdio" }, + filetypes = { "python" }, + root_markers = { + "pyrightconfig.json", + "pyproject.toml", + "setup.py", + "setup.cfg", + "requirements.txt", + "Pipfile", + ".git", + }, + + settings = { + basedpyright = { + analysis = { + autoSearchPaths = true, + useLibraryCodeForTypes = true, + diagnosticMode = "openFilesOnly", + }, + }, + }, +} diff --git a/lua/config/lsp.lua b/lua/config/lsp.lua index 059b754..8596654 100644 --- a/lua/config/lsp.lua +++ b/lua/config/lsp.lua @@ -12,6 +12,8 @@ vim.lsp.enable({ "nixd", + "basedpyright", + "qmlls", "rust-analyzer", |
