mirror of
https://github.com/LazyVim/LazyVim.git
synced 2026-07-25 14:01:06 +00:00
feat(python): default to new ruff instead of ruff_lsp
This commit is contained in:
parent
43dbe0e60d
commit
af19cc2d9b
1 changed files with 9 additions and 2 deletions
|
|
@ -2,11 +2,12 @@ if lazyvim_docs then
|
||||||
-- LSP Server to use for Python.
|
-- LSP Server to use for Python.
|
||||||
-- Set to "basedpyright" to use basedpyright instead of pyright.
|
-- Set to "basedpyright" to use basedpyright instead of pyright.
|
||||||
vim.g.lazyvim_python_lsp = "pyright"
|
vim.g.lazyvim_python_lsp = "pyright"
|
||||||
vim.g.lazyvim_python_ruff = "ruff_lsp"
|
-- Set to "ruff_lsp" to use the old LSP implementation version.
|
||||||
|
vim.g.lazyvim_python_ruff = "ruff"
|
||||||
end
|
end
|
||||||
|
|
||||||
local lsp = vim.g.lazyvim_python_lsp or "pyright"
|
local lsp = vim.g.lazyvim_python_lsp or "pyright"
|
||||||
local ruff = vim.g.lazyvim_python_ruff or "ruff_lsp"
|
local ruff = vim.g.lazyvim_python_ruff or "ruff"
|
||||||
|
|
||||||
return {
|
return {
|
||||||
recommended = function()
|
recommended = function()
|
||||||
|
|
@ -44,6 +45,12 @@ return {
|
||||||
},
|
},
|
||||||
ruff = {
|
ruff = {
|
||||||
enabled = ruff == "ruff",
|
enabled = ruff == "ruff",
|
||||||
|
cmd_env = { RUFF_TRACE = "messages" },
|
||||||
|
init_options = {
|
||||||
|
settings = {
|
||||||
|
logLevel = "error",
|
||||||
|
},
|
||||||
|
},
|
||||||
},
|
},
|
||||||
[ruff] = {
|
[ruff] = {
|
||||||
keys = {
|
keys = {
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue