diff options
| author | Dionisio E Alonso <baco@users.noreply.github.com> | 2024-03-19 02:44:36 -0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-03-19 13:44:36 +0800 |
| commit | eb012f03bb3b4aca9e875d146008b923d0e07e65 (patch) | |
| tree | b8f4fb398fac56a8defd61c96fa391f9e56b5f21 /lua | |
| parent | docs: update server_configurations.md (diff) | |
| download | nvim-lspconfig-eb012f03bb3b4aca9e875d146008b923d0e07e65.tar nvim-lspconfig-eb012f03bb3b4aca9e875d146008b923d0e07e65.tar.gz nvim-lspconfig-eb012f03bb3b4aca9e875d146008b923d0e07e65.tar.bz2 nvim-lspconfig-eb012f03bb3b4aca9e875d146008b923d0e07e65.tar.lz nvim-lspconfig-eb012f03bb3b4aca9e875d146008b923d0e07e65.tar.xz nvim-lspconfig-eb012f03bb3b4aca9e875d146008b923d0e07e65.tar.zst nvim-lspconfig-eb012f03bb3b4aca9e875d146008b923d0e07e65.zip | |
fix(basepyright): correct command (#3082)
* feat: add basedpyright support
* fix(basedpyright): correct settings schema
Settings are stored under a different key for this fork. Instead of
using the original `python` key, now settings specific to this LSP
server are stored under `basedpyright` map key.
* fix(basedpyright): correct plugin command
The command was doing nothing because as `python` is no longer the
default namespace for settings, for this LSP server,
`client.settings.python` has a `nil` value. Hence the table couldn't be
extended.
Diffstat (limited to 'lua')
| -rw-r--r-- | lua/lspconfig/server_configurations/basedpyright.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lua/lspconfig/server_configurations/basedpyright.lua b/lua/lspconfig/server_configurations/basedpyright.lua index a360e8c9..172ed237 100644 --- a/lua/lspconfig/server_configurations/basedpyright.lua +++ b/lua/lspconfig/server_configurations/basedpyright.lua @@ -32,7 +32,7 @@ local function set_python_path(path) } for _, client in ipairs(clients) do if client.settings then - client.settings.python = vim.tbl_deep_extend('force', client.settings.python, { pythonPath = path }) + client.settings.python = vim.tbl_deep_extend('force', client.settings.python or {}, { pythonPath = path }) else client.config.settings = vim.tbl_deep_extend('force', client.config.settings, { python = { pythonPath = path } }) end |
