add ruff-lsp, clean lspconfig stuff a bit

This commit is contained in:
Szwendacz99 2022-12-30 11:25:56 +01:00
parent 9e1d110d97
commit 696193a3fd
3 changed files with 39 additions and 17 deletions

View file

@ -2,6 +2,7 @@
" as it can contain some theme stuff that " as it can contain some theme stuff that
" checks for termguicolors " checks for termguicolors
set termguicolors set termguicolors
highlight clear
" load main lua file with additional configs " load main lua file with additional configs
lua require("initializer") lua require("initializer")

View file

@ -4,11 +4,12 @@ require("mason-lspconfig").setup({
"bashls", "bashls",
"pyright", "pyright",
"pylsp", "pylsp",
"ruff-lsp",
--"python-jedi-server", --"python-jedi-server",
--"pyre", --"pyre",
"perlnavigator", "perlnavigator",
"dockerls", "dockerls",
"kotlin_language_server", --"kotlin_language_server",
"intelephense", "intelephense",
"eslint", "eslint",
"tsserver", "tsserver",

View file

@ -106,8 +106,24 @@ require 'lspconfig'.pylsp.setup {
, settings = { , settings = {
pylsp = { pylsp = {
plugins = { plugins = {
rope_autoimport = { enabled = true, memory = true },
rope_completion = { enabled = true, eager = true },
jedi_completion = {
enabled = true,
include_params = true,
include_class_objects = true,
include_function_objects = true,
fuzzy = true,
eager = true,
},
jedi_hover = { enabled = true },
jedi_references = { enabled = true },
jedi_signature_help = { enabled = true },
jedi_symbols = { enabled = true },
--ruff = { enabled = true },
flake8 = { flake8 = {
enabled = true enabled = false -- ruff_lsp
}, },
pylint = { pylint = {
enabled = true, enabled = true,
@ -123,8 +139,8 @@ require 'lspconfig'.pylsp.setup {
autopep8 = { autopep8 = {
enabled = false enabled = false
}, },
pyflakes = { enabled = true }, pyflakes = { enabled = false }, -- ruff_lsp
pyodestyle = { enabled = true }, pyodestyle = { enabled = false }, -- ruff_lsp
pydocstyle = { pydocstyle = {
enabled = true, enabled = true,
ignore = { ignore = {
@ -138,14 +154,18 @@ require 'lspconfig'.pylsp.setup {
} }
} }
} }
--require'lspconfig'.jedi_language_server.setup{ require'lspconfig'.ruff_lsp.setup{
--on_attach = on_attach, on_attach = on_attach,
--capabilities = capabilities, capabilities = capabilities,
--} }
require 'lspconfig'.pyright.setup { require 'lspconfig'.pyright.setup {
on_attach = on_attach, on_attach = on_attach,
capabilities = capabilities, capabilities = capabilities,
} }
--require'lspconfig'.jedi_language_server.setup{
--on_attach = on_attach,
--capabilities = capabilities,
--}
--require 'lspconfig'.pyre.setup { --require 'lspconfig'.pyre.setup {
--on_attach = on_attach, --on_attach = on_attach,
--capabilities = capabilities, --capabilities = capabilities,
@ -162,10 +182,10 @@ require 'lspconfig'.dockerls.setup {
on_attach = on_attach, on_attach = on_attach,
capabilities = capabilities, capabilities = capabilities,
} }
require 'lspconfig'.kotlin_language_server.setup { --require 'lspconfig'.kotlin_language_server.setup {
on_attach = on_attach, --on_attach = on_attach,
capabilities = capabilities, --capabilities = capabilities,
} --}
require 'lspconfig'.intelephense.setup { require 'lspconfig'.intelephense.setup {
on_attach = on_attach, on_attach = on_attach,
capabilities = capabilities, capabilities = capabilities,