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
" checks for termguicolors
set termguicolors
highlight clear
" load main lua file with additional configs
lua require("initializer")

View file

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

View file

@ -106,8 +106,24 @@ require 'lspconfig'.pylsp.setup {
, settings = {
pylsp = {
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 = {
enabled = true
enabled = false -- ruff_lsp
},
pylint = {
enabled = true,
@ -123,8 +139,8 @@ require 'lspconfig'.pylsp.setup {
autopep8 = {
enabled = false
},
pyflakes = { enabled = true },
pyodestyle = { enabled = true },
pyflakes = { enabled = false }, -- ruff_lsp
pyodestyle = { enabled = false }, -- ruff_lsp
pydocstyle = {
enabled = true,
ignore = {
@ -138,17 +154,21 @@ require 'lspconfig'.pylsp.setup {
}
}
}
--require'lspconfig'.jedi_language_server.setup{
--on_attach = on_attach,
--capabilities = capabilities,
--}
require 'lspconfig'.pyright.setup {
on_attach = on_attach,
capabilities = capabilities,
require'lspconfig'.ruff_lsp.setup{
on_attach = on_attach,
capabilities = capabilities,
}
require 'lspconfig'.pyright.setup {
on_attach = on_attach,
capabilities = capabilities,
}
--require'lspconfig'.jedi_language_server.setup{
--on_attach = on_attach,
--capabilities = capabilities,
--}
--require 'lspconfig'.pyre.setup {
--on_attach = on_attach,
--capabilities = capabilities,
--on_attach = on_attach,
--capabilities = capabilities,
--}
require 'lspconfig'.sourcekit.setup {
on_attach = on_attach,
@ -162,10 +182,10 @@ require 'lspconfig'.dockerls.setup {
on_attach = on_attach,
capabilities = capabilities,
}
require 'lspconfig'.kotlin_language_server.setup {
on_attach = on_attach,
capabilities = capabilities,
}
--require 'lspconfig'.kotlin_language_server.setup {
--on_attach = on_attach,
--capabilities = capabilities,
--}
require 'lspconfig'.intelephense.setup {
on_attach = on_attach,
capabilities = capabilities,