nixos/config/nvim/lua/lsp/formatting.lua

12 lines
300 B
Lua

local lsp_formatting = function(bufnr)
vim.lsp.buf.format {
bufnr = bufnr,
timeout_ms = 2000,
async = true,
filter = function(client)
return client.name ~= "jedi_language_server" and client.name ~= "lua_ls"
end,
}
end
return lsp_formatting