From 41e667d58a33416e348874bd0b8478838c12835b Mon Sep 17 00:00:00 2001 From: David Ibia Date: Tue, 30 Jan 2024 16:06:14 +0100 Subject: [PATCH] chore(lsp-config.lua): update configuration for pylsp and emmet_ls feat(lsp-config.lua): enable rope_autoimport, flake8, pyflakes, and pycodestyle plugins for pylsp refactor(lsp-config.lua): comment out jedi_language_server configuration --- lua/absolute/after/lsp-config.lua | 33 +++++++++++++++++++++---------- 1 file changed, 23 insertions(+), 10 deletions(-) diff --git a/lua/absolute/after/lsp-config.lua b/lua/absolute/after/lsp-config.lua index f4f7070..6ba081a 100644 --- a/lua/absolute/after/lsp-config.lua +++ b/lua/absolute/after/lsp-config.lua @@ -113,25 +113,38 @@ lspconfig["emmet_ls"].setup({ on_attach = on_attach, filetypes = { "html", "typescriptreact", "javascriptreact", "css", "sass", "scss", "less", "svelte", "vue" }, }) - -- configure python lsp lspconfig["pylsp"].setup({ + filetypes = { "python" }, capabilities = capabilities, on_attach = on_attach, pylsp = { - plugins = { - jedi_completion = { - include_params = true, + pylsp = { + plugins = { + rope_autoimport = { + enabled = true, + completions = { enabled = true }, + }, + flake8 = { enabled = true }, + jedi_completion = { + include_params = true, + }, + pyflakes = { enabled = true }, + pycodestyle = { + enabled = true, + ignore = { "E231" }, + maxLineLength = 150, + }, }, }, }, }) - --- configure jedi language server -lspconfig["jedi_language_server"].setup({ - capabilities = capabilities, - on_attach = on_attach, -}) +-- +-- -- configure jedi language server +-- lspconfig["jedi_language_server"].setup({ +-- capabilities = capabilities, +-- on_attach = on_attach, +-- }) -- configure docker server lspconfig["dockerls"].setup({