mirror of
https://github.com/LazyVim/LazyVim.git
synced 2025-07-04 14:34:33 +02:00
feat(python): allow configuring other python lsp servers than pyright, basedpyright
This commit is contained in:
parent
9e07a6615a
commit
3e5a5dd621
1 changed files with 7 additions and 2 deletions
|
@ -4,6 +4,8 @@ if lazyvim_docs then
|
||||||
vim.g.lazyvim_python_lsp = "pyright"
|
vim.g.lazyvim_python_lsp = "pyright"
|
||||||
end
|
end
|
||||||
|
|
||||||
|
local lsp = vim.g.lazyvim_python_lsp or "pyright"
|
||||||
|
|
||||||
return {
|
return {
|
||||||
{
|
{
|
||||||
"nvim-treesitter/nvim-treesitter",
|
"nvim-treesitter/nvim-treesitter",
|
||||||
|
@ -18,10 +20,13 @@ return {
|
||||||
opts = {
|
opts = {
|
||||||
servers = {
|
servers = {
|
||||||
pyright = {
|
pyright = {
|
||||||
enabled = vim.g.lazyvim_python_lsp ~= "basedpyright",
|
enabled = lsp == "pyright",
|
||||||
},
|
},
|
||||||
basedpyright = {
|
basedpyright = {
|
||||||
enabled = vim.g.lazyvim_python_lsp == "basedpyright",
|
enabled = lsp == "basedpyright",
|
||||||
|
},
|
||||||
|
[lsp] = {
|
||||||
|
enabled = true,
|
||||||
},
|
},
|
||||||
ruff_lsp = {
|
ruff_lsp = {
|
||||||
keys = {
|
keys = {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue