Added python lsp and massive refactor
This commit is contained in:
19
lua/plugins/formatters.lua
Normal file
19
lua/plugins/formatters.lua
Normal file
@@ -0,0 +1,19 @@
|
||||
return {
|
||||
"stevearc/conform.nvim",
|
||||
opts = {},
|
||||
config = function()
|
||||
require("conform").setup({
|
||||
formatters_by_ft = {
|
||||
lua = { "stylua" },
|
||||
python = { "isort", "ruff_format" },
|
||||
},
|
||||
})
|
||||
vim.api.nvim_set_keymap(
|
||||
"n",
|
||||
"<Leader>f",
|
||||
":lua require('conform').format()<CR>",
|
||||
{ noremap = true, silent = true }
|
||||
)
|
||||
end,
|
||||
keys = "<leader>f", -- Optionally specify here to load the plugin on this keypress
|
||||
}
|
||||
Reference in New Issue
Block a user